php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #23100 bad arugument in function.implode
Submitted: 2003-04-07 16:09 UTC Modified: 2003-04-07 16:50 UTC
From: support at daystardistributing dot com Assigned:
Status: Not a bug Package: MySQL related
PHP Version: 4.3.1 OS: Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: support at daystardistributing dot com
New email:
PHP Version: OS:

 

 [2003-04-07 16:09 UTC] support at daystardistributing dot com
When trying to use my search engine using this code

function boolean_sql_select_short($string,$match){
	$match_a = explode(',',$match);
	$score_unit_weight = .2;
	for($ith=0;$ith<count($match_a);$ith++){
		$score_a[$ith] =
			"$score_unit_weight*(
			LENGTH($match_a[$ith]) -
			LENGTH(REPLACE(LOWER('$match_a[$ith]'),LOWER('$string'),'')))/LENGTH('$string')";
	}

               $score = implode(" + ",$score_a);

	return $score;
}

I get the following retuned error:

Warning: implode() [function.implode]: Bad arguments. in /*/*/public_html/search/mysql_boolean.txt on line 45
You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ') - LENGTH(REPLACE(LOWER(''),LOWER('eyb'),'')))/LENGTH('eyb'

Need help solving this issue, thanks.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-04-07 16:50 UTC] jay@php.net
This isn't the right place to look for PHP support. If you 
need help, please check out the php-general ("General user 
list") mailing list.  
 
http://www.php.net/mailing-lists.php 
 
J 
 
 
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 06:01:29 2024 UTC