Home arrow Contact Us
integrated search
  Welcome, Guest. Please login or register.
December 04, 2008, 07:59:47 PM
Home New Posts Search Calendar


Login with username, password and session length
Forum  |  MamboHacks.com  |  Mambo-SMF Forum 1.3.0 Support  |  Topic: integrated search « previous next »
Pages: [1] Go Down Print
Author Topic: integrated search  (Read 4029 times)
Geoffrey Makstutis
Newbie
*

Karma: +0/-0
Offline Offline

Posts: 3


View Profile
integrated search
« on: August 08, 2005, 09:11:03 AM »

Hi,

I'm wondering if anyone has (or knows of) a mambot that will allow you to search SMF forums from within the main Mambo search function? I noted that the SMF-Bridge project has just released a mambo to do this. I've had a look at it, but (not being a very advanced PHP/Mambo coder) I couldn't see what would be needed to make it work for Mambo-SMF.

Anyone willing to take up the gauntlet?
Logged
cowboy
Administrator
Hero Member
*****

Karma: +30/-0
Offline Offline

Posts: 663



View Profile WWW
Re: integrated search
« Reply #1 on: August 09, 2005, 12:58:54 PM »

Geoffrey,

There's probably some restrictions on the code, because I don't see why it wouldn't work. I can check that when I get a chance. It should be fairly easy.
Logged
d3vlabs
Newbie
*

Karma: +1/-0
Offline Offline

Posts: 16


View Profile
Re: integrated search
« Reply #2 on: August 09, 2005, 01:18:26 PM »

Here's the file's URL: http://mamboforge.net/frs/download.php/6942/smf.search.zip

This is the readme that comes with the file

Code:
IMPORTANT! THE INDEX.PHP FOR YOUR MAMBO TEMPLATE MUST BE MODIFIED!

The SMF bridge instructions tell you to add this code immediately above </head>:

global $sc, $context;

if (!defined('SMF')){
  require ("administrator/components/com_smf/config.smf.php");
  require_once ($smf_path."/SSI.php");
}

$sc = &$context['session_id'];

You need to change this code to the following:

global $sc, $context;

if (!defined('SMF')){
  require ("administrator/components/com_smf/config.smf.php");
    require ($smf_path . "/Settings.php");
  require_once ($smf_path."/SSI.php");
}

$sc = &$context['session_id'];

Simply add the missing line between the require statements.

If you don't do this, your site will not function!

I attempted this with Latest MamboHacks bridge and Latest Mambo. The bot DID NOT WORK. cowboy, post your thoughts or maybe post your working version  Grin please. This is a heavily anticipated feature...at least by me
Logged
d3vlabs
Newbie
*

Karma: +1/-0
Offline Offline

Posts: 16


View Profile
Re: integrated search
« Reply #3 on: August 14, 2005, 06:21:38 AM »

err I didnt realized that MamboHacks SMF bridge modifieds mambo/index.php and not mambo/templates/templatename/index.php. This is better actually since it will work on any template you have. To make smf searchbot work on your site using Mambohacks.com bridge add this code to your mambo/index.php:

Code:
if (file_exists($smf_path."/Settings.php"))
require ($smf_path . "/Settings.php");

right after

Code:
if (file_exists($smf_path."/SSI.php"))
require_once ($smf_path."/SSI.php");[

This should be around line 28 under //MAMBOHACKS.COM category. Make sure you do this after you patch your index.php file via bridge's backend component.
This is tested on Mambo 4.5.2.3 with the latest bridge. Take care.
Logged
cowboy
Administrator
Hero Member
*****

Karma: +30/-0
Offline Offline

Posts: 663



View Profile WWW
Re: integrated search
« Reply #4 on: August 15, 2005, 11:28:20 AM »

d3vlabs,

Nice job, it worked.

It just return to many result, like 1000+ for me. It still needs to implement result paging.
Logged
Pages: [1] Go Up Print 
Forum  |  MamboHacks.com  |  Mambo-SMF Forum 1.3.0 Support  |  Topic: integrated search « previous next »
Jump to:  



Login with username, password and session length

Powered by MySQL Powered by PHP Forum | Powered by SMF 1.0.5 & Mambo-SMF.
© 2001-2005, Lewis Media. All Rights Reserved.
Valid XHTML 1.0! Valid CSS!
None of the text or images in this public website may be copied without the expressed written consent of the authors.
Copyright 2005 by MamboHacks.com. Powered by Mambo. All rights reserved.
TERMS OF USE