hello,
i have something like this
search:_______ search1:___________ submit btn
how can i search for something from the same table in the database considering both search fields?
I've tried this code nut it doesn't work.
thanks
if($search == '')
{
$smarty->assign('Error','Please enter any string!');
$z=1;
}
elseif($type == 'like')
{
$sql = 'SELECT * FROM topic WHERE Title LIKE '."'$search%'".' AND Title1 LIKE '."'$search1%'";
}
elseif($type == 'exact')
{
$sql = 'SELECT * FROM topic WHERE MATCH (Title) AGAINST ("'.$search.'") AND (Title1) AGAINST ("'.$search1.'")';