php-db | 2001071
Date: 07/09/01
- Next message: Frank M. Kromann: "Re: [PHP-DB] testing ODBC + MSSQL connection locally"
- Previous message: Bob Hall: "Re: [PHP-DB] Use of Like"
- Next in thread: Frank M. Kromann: "Re: [PHP-DB] a simple question"
- Maybe reply: Frank M. Kromann: "Re: [PHP-DB] a simple question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
can somebody help me with the following code:
function multi_word($title) {
$array = explode (" ", $input);
$number = count ($array);
if ($number > 1) {
return true;
} else{
return false;
}
}
if ($category) {
$Query = "SELECT * from $TableName WHERE ((category)=$category)";
} else {
if ($title) {
if (multi_word($title)) {
print "one word at a time for now";
die();
} else {
$Query = "SELECT * from $TableName WHERE title LIKE '%$title%'";
}
}
}
when i try to pass in a multi-word string it doesnt print anything. I have
tested the function and I know it works allright... if anyone could help
that would be great.
Brad
-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe <email protected> For additional commands, e-mail: php-db-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: Frank M. Kromann: "Re: [PHP-DB] testing ODBC + MSSQL connection locally"
- Previous message: Bob Hall: "Re: [PHP-DB] Use of Like"
- Next in thread: Frank M. Kromann: "Re: [PHP-DB] a simple question"
- Maybe reply: Frank M. Kromann: "Re: [PHP-DB] a simple question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

