0
Good morning I have an input that generates a variable $phrase with his dice.
$phrase = "%". $phrase."%";
In php Mysql I refer to sql:
$comandoSql = select id from items where descricao like ?;
$stmt = $conexao->prepare($comandoSql) or trigger_error("triggererror ".$conexao->error);
$stmt->bind_param('s',$frase);
$stmt->execute()
If I type "notebook font", You will find "%notebook font%"
I want that when I type "notebook font", Search for: "%source%" and "%notebook%"
If it is necessary I take the bind_params, I know I would have to explode and separate in a vector, I accept this code too, reformulating my sql query and taking the bind_params.
But if you can use the bind, it would be better.
It’s like by bind_params ?
If not, what is the same variable explode code and what do I put to close the command ?