MySQLi Server Behaviour
Been testing this and it appears that when creating a recordset using the LIKE Filter, it will not return any results. I tested it using the URL variable (if(isset)). It works using = Filter and searching for the same word. I also tried altering the code slighly to include %;
So this:
$Recordset1->bindParam("s", "".(isset($_GET['name_mnu'])?$_GET['name_mnu']:"") ."", "-1"); //colname
Becomes this:
$Recordset1->bindParam("s", "%".(isset($_GET['name_mnu'])?$_GET['name_mnu']:"") ."%", "-1"); //colname
Looking at this a littler further, I also note that when testing to the LIKE filter within the DW dialogue, there so an error there too. Maybe it is connected?
This is the subsequent Recordset created;
<?php
$Recordset1 = new WA_MySQLi_RS("Recordset1",$db,1);
$Recordset1->setQuery("SELECT id_mnu, name_mnu FROM menu_mnu WHERE name_mnu LIKE ?");
$Recordset1->bindParam("s", "".(isset($_GET['name_mnu'])?$_GET['name_mnu']:"") ."", "-1"); //colname
$Recordset1->execute();
?>
Can you shed some light on this?
It seems when one uses a term like 'Ladies Shoes' it works but when we use a single word like Shoes it will not return the same result even though the word 'Shoes is in the term Ladies Shoes?