Finished-[6.4-6.5] Search FIX - 03/08/2005 7:57 AM
Mod Name / Version: Search FIX
Description: Fixes the search modules found in UBBT 6.4+
Unlike conventional search engines such as google and yahoo... When entering multiple search terms to UBBT, you are required to use "+" or "-" in front of each word. If you don't, your results will display ANY matches of ANY of the words.
This fixes the "ANY, ALL or SOME" issue and returns functionality of your board's search engine to what most users are familiar with in the real world.
After inserting this code, the "ANY" feature will no longer work, but the plus side is that your users will no longer be afraid to use your search engine since they will have more positive results returned of what they are looking for.
(it basically returns your search "word" engine to that of what it was in version 6.3 and prior)
Working Under: UBB.Threads 6.4-6.5
Mod Status: Finished
Any pre-requisites: none
Author(s): id242
Date: 03/07/05
Credits: Thanks to Myke for the update!
Files Altered: dosearch.php
New Files: none
Database Altered: no
Info/Instructions: in dosearch.php, find:
insert BEFORE it:
Code has been updated with Myke's addtional code from #128269 - 06/09/05 04:32 AM, THANK YOU!
[Version numbers edited: Thanks for the update twisty The correct ubbt version numbers that this fix works under has been corrected - also tested and working fine in a 6.5 install]
Disclaimer: Please backup every file that you intend to modify.
If the modification modifies the database, it's a good idea to backup your database before doing so.
Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you'll need to restore unmodified files.
Description: Fixes the search modules found in UBBT 6.4+
Unlike conventional search engines such as google and yahoo... When entering multiple search terms to UBBT, you are required to use "+" or "-" in front of each word. If you don't, your results will display ANY matches of ANY of the words.
This fixes the "ANY, ALL or SOME" issue and returns functionality of your board's search engine to what most users are familiar with in the real world.
After inserting this code, the "ANY" feature will no longer work, but the plus side is that your users will no longer be afraid to use your search engine since they will have more positive results returned of what they are looking for.
(it basically returns your search "word" engine to that of what it was in version 6.3 and prior)
Working Under: UBB.Threads 6.4-6.5
Mod Status: Finished
Any pre-requisites: none
Author(s): id242
Date: 03/07/05
Credits: Thanks to Myke for the update!
Files Altered: dosearch.php
New Files: none
Database Altered: no
Info/Instructions: in dosearch.php, find:
Code
<br />// --------------------------------------------------------- <br />// The forums we are searching will be in a different format <br />// depending on where we are coming from <br />
insert BEFORE it:
Code
<br />// --------------------------------------------------------- <br />// FIX Search code ===START=== <br />if ($Words != "") { <br /> if (!strstr($Words, '"')) { <br /> if (!strstr($Words, " +")) { <br /> $Words = str_replace(" ", " +", $Words); <br />// $Words = "+".$Words; <br /> } <br /> } <br /> $Words = str_replace(" +-", " -", $Words); <br /> $Words = str_replace(" ++", " +", $Words); <br />} <br />// FIX Search code ===END=== <br />
Code has been updated with Myke's addtional code from #128269 - 06/09/05 04:32 AM, THANK YOU!
[Version numbers edited: Thanks for the update twisty The correct ubbt version numbers that this fix works under has been corrected - also tested and working fine in a 6.5 install]
Disclaimer: Please backup every file that you intend to modify.
If the modification modifies the database, it's a good idea to backup your database before doing so.
Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you'll need to restore unmodified files.