I have: 14,10,13,12,11,9 in an array called loosephotos (which I can explode into a string if needed...)
I want to query mySQL such that I ask the database, return all rows where ID is 14 or 10 or 13 or 12 or 11 or 9. I guess another way to say it would be, return all rows where any ID equals any array value....
Is there an easy way to do this without looping? Something like:
resultgrab = mysql_query("select * from $itemstable WHERE ID = '$loosephotos' && xrestricted >= $accesslevel ORDER BY '$sortby' $desc limit $limit");
I can explode or do whatever i need to do format it first, and if i HAVE to loop it i will, i just really want to figure this out...
Thanks