how do i include optional variables in a query
for example i want the query to return all rows where variable 1 is found in either field 1 OR field 2
the query i have at the moment looks like this
Code: Select all
$result = mysql_query("Select * from themes where related_theme1= '$theme_id' OR related_theme2 = '$theme_id");thanks in advance