PDA

View Full Version : Embedding phpdig into a forum


Gus58
06-20-2004, 01:49 AM
How do I embed or insert phpdig into my forums like its done here? And how do I make the spider search only my forums and nothing else. I am running phbbb 2.0.8
Thx Gus

bloodjelly
06-20-2004, 11:28 AM
Hi Gus - phpBB already has a good search engine, and I'm pretty sure the forum search engine here is run by vBulletin, not phpDig. But if you wanted to use Dig instead, you can setup up your "robots.txt" file to ignore all directories but the phpBB2 directory. Placing the actual search form into the forums would take a little php/html knowhow, but an alternative would be to simply link to phpDig's "search.php" page from PhpBB.

Gus58
06-21-2004, 12:02 AM
I mean the demo search at the bottom of the forum menu, not the v bulletin one. Thanx for the help. I'll have a look at the robots.txt. I find phpbb's search abyssmal, thats why I looked here.
Gus

Gus58
06-21-2004, 12:24 AM
I haven't got a robots.txt file in any directory

bloodjelly
06-21-2004, 01:11 AM
The robots.txt file tells phpDig (and other search engines) which directories you don't want scanned. So if you disallow all your directories but the one you want scanned in the robots.txt file, you'll effectively limited your scan to that directory.

The file should go in your root directory, or else it won't work. Here is more info on it: http://www.robotstxt.org/wc/exclusion.html#robotstxt

As for embedding, check out the HTML source code that starts with this:

<form action='demo/search.php' method='get'>
<input type='hidden' name='template_demo' value=''/>
<input type='hidden' name='site' value=''/>
<input type='hidden' name='path' value=''/>
<input type='hidden' name='result_page' value='search.php'/>

......</form>

Also read the documentation (link at top of page). This has the answer to both your questions. Someone else might know a better way of limiting phpDig besides the robots.txt file (which will also ban google and other good spiders). Good luck.

Gus58
06-22-2004, 11:40 PM
Ok I have robots.txt installed and I need to know where to point it to so that it picks up the text in the posts in my forums. I'm running phpbb and need to know which file/s to allow the robot to search. Thx

bloodjelly
06-22-2004, 11:46 PM
Robots.txt is exclusionary (at least right now) - that is, you tell it which folders NOT to scan. Search google to learn how to use it or check the link I posted.

Gus58
06-23-2004, 12:01 AM
Yeah I know its exclusionary, I have everything blocked at the moment. ie I have all files and directories listed in it...... It took me an hour to set robots.txt up. Sorry I may not have explained myself correctly. I need to know what files do I allow the robots access to. What files do I delete from my robots.txt to make my forums searchable in phpbb. I have tried google.......

bloodjelly
06-23-2004, 12:56 AM
If I understand you correctly, to make phpBB searchable (and only phpBB) by phpDig, you would do what you exactly what you have done with the robots.txt but leave out the directory that phpBB is located in. If you haven't told the spider to avoid that directory, it will scan it, as long as the spider can find it. So you must at least let the spider scan your main page or a page with links to phpBB on it.

Gus58
06-25-2004, 12:41 AM
Ok, thanx, have been mucking around with some different settings and I'm starting to get results.....