I'm new to php and i don't have the formal study, since i study it myself i have a problem and i hope someone can help me.. :(
I have and array
$array = array("where","are","you" and so on.....);
and i want to search the database with all those values
like
$sql_res1 =mysql_query("select * from lady_vega where react like '%$array[0]%'");
$sql_res2 =mysql_query("select * from lady_vega where react like '%$array[1]%'");
$sql_res3 =mysql_query("select * from lady_vega where react like '%$array[2]%'");
.... and so on
there are times that the array don't have the exact number of values.
and someone said to me that loop could be a help...
but i don't know how...
and i also want the results of each mysql query will be stored like this so that i can i dentify which results are from...
$row1 = mysql_fetch_array($sql_res1);
$row2 = mysql_fetch_array($sql_res2);
$row3 = mysql_fetch_array($sql_res3);
... so on
i hope there would a possible solution/technique to this..