Hey i have a script like this.
$date=mysql_query("select * from table where date1 <= $tag and date2 >=$tag" );
but it gives an error while i use sum values other thqan number for $tag.
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\pagese.php on line 218
i want it to function like it should run if $tag is not a number.
or if thats not possible i want it to ignore this eror that is dont display any error instead retrn nothig.
i think u dint get mmy question dude..
its just a part of my code.. this code is like searching for sumthing.. its not mentioned whether it is searching for apples or orange. nd if $tag is sumthing related to apples. then it wil bring out the result and that time.. this orange should ignore results because parameters doesnt match it.
this $date is one of the condition. and this has parameters of intigers
i have $place too. so if $tag is text then $place gives result. and $date gives this error. i dont want it to giv any error. it shud jst ignore wen it is int type
$date=mysql_query("select * from table where date1 <= $tag and date2 >=$tag" );
but it gives an error while i use sum values other thqan number for $tag.
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\pagese.php on line 218
i want it to function like it should run if $tag is not a number.
or if thats not possible i want it to ignore this eror that is dont display any error instead retrn nothig.
i think u dint get mmy question dude..
its just a part of my code.. this code is like searching for sumthing.. its not mentioned whether it is searching for apples or orange. nd if $tag is sumthing related to apples. then it wil bring out the result and that time.. this orange should ignore results because parameters doesnt match it.
this $date is one of the condition. and this has parameters of intigers
i have $place too. so if $tag is text then $place gives result. and $date gives this error. i dont want it to giv any error. it shud jst ignore wen it is int type