How do I have to do to search an exact phrase... why does the next script search all words all over the text...
To be clearer.. if I want to search "I want to go" I want to find that phrase and not the words spreaded... "...want. I go to"
SELECT * FROM db_leggi WHERE 1=1");
if(!empty($cerca))
$select .= sprintf(" AND titolo_l LIKE '%%%s%%'", $cerca);
if(!empty($cerca))
$select .= sprintf(" OR numero_l LIKE 'EXACT'", $cerca);
To be clearer.. if I want to search "I want to go" I want to find that phrase and not the words spreaded... "...want. I go to"
SELECT * FROM db_leggi WHERE 1=1");
if(!empty($cerca))
$select .= sprintf(" AND titolo_l LIKE '%%%s%%'", $cerca);
if(!empty($cerca))
$select .= sprintf(" OR numero_l LIKE 'EXACT'", $cerca);