PhpDig.net

Go Back   PhpDig.net > PhpDig Forums > Bug Tracker

Reply
 
Thread Tools
Old 12-22-2004, 11:40 AM   #1
BBUCommander
Green Mole
 
Join Date: Dec 2004
Posts: 1
Question Certain Search Strings Causing Errors

Whenever I attempt to make a search using certain strings such as 'news' or 'ah', the search engine will crash and give me this error repeatedly:

Quote:
Notice: Uninitialized string offset: 0 in F:\Documents and Settings\Jesse\My Documents\sites\Animal Rights\testserver\search\phpdig\libs\search_function.php on line 597
Yet, when I type something like 'ahbe' as the query string, it works fine, so I do not believe that it has something to do with the string length. Any ideas about what could be causing this error?

I'm using v 1.8.6 of PhpDig.


BTW, hope everyone is enjoying the holidays.

Last edited by BBUCommander; 12-22-2004 at 11:48 AM.
BBUCommander is offline   Reply With Quote
Old 12-22-2004, 11:53 PM   #2
vinyl-junkie
Purple Mole
 
Join Date: Jan 2004
Posts: 694
If it were a problem with phpdig, I would think I'd get the same error when I try the same search on my site. However, that worked fine for me.

Did you make any mods to phpdig? If so, I'd start looking there for a problem.
vinyl-junkie is offline   Reply With Quote
Old 01-04-2005, 11:15 PM   #3
Charter
Head Mole
 
Charter's Avatar
 
Join Date: May 2003
Posts: 2,539
It's a bug... to fix do the following:

In search_function.php find:
PHP Code:
else {
    
$num_in_strings_arr count($strings);
    
$leven_final "";
    
$leven_sum 0
And replace with:
PHP Code:
else {
    if (
is_array($strings)) {
        
$strings array_values($strings);
        
$num_in_strings_arr count($strings);
    }
    else { 
$num_in_strings_arr 0; }
    
$leven_final "";
    
$leven_sum 0
__________________
Responses are offered on a voluntary if/as time is available basis, no guarantees. Double posting or bumping threads will not get your question answered any faster. No support via PM or email, responses not guaranteed. Thank you for your comprehension.
Charter is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Spidering errors Dave A Troubleshooting 1 01-20-2006 05:31 AM
404 errors petritur Troubleshooting 1 07-13-2004 12:56 PM
Install errors under Xitami Orb Script Installation 4 05-09-2004 11:56 AM
Indexing duplicate descriptions and keywords causing false search results jerrywin5 Mod Requests 3 05-04-2004 09:27 AM
problems on the first result page with multiple search strings heiko Troubleshooting 3 10-15-2003 05:06 AM


All times are GMT -8. The time now is 08:55 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright © 2001 - 2005, ThinkDing LLC. All Rights Reserved.