Am Stranded and am requesting for help.
I am developing a car sales system but am unable to compine search criteria e.g the model of the car and price range; body, category and pricerange; model, transmission, fueltype and condition e.t.c
Someone Kindly help me.
The code below is able to search each individual feature on its own.

mysql_connect($hostname, $username, $password) or die("Unable to connect to MySQL");
$category = $_POST['Category'];
//default form values
$category_default ="-select-";

$default_values = array($body_default, $category_default, $Model_default, $price_default, $Transmission_default, $Fuel_default, $Colour_default,$Condition_default );

$search = array($body, $category, $Model,$price, $Transmission, $Fuel, $Colour, $Condition);

foreach( $default_values as $default)
foreach ($search as $value)

$sql="SELECT * FROM $tbl where body='".$search[0]."' || category = '".$search[1]."' || model = '".$search[2]."' || pricerange = '".$search[3]."'
|| transmission = '".$search[4]."' || fueltype = '".$search[5]."' || color = '".$search[6]."' || carcondition = '".$search[7]."' && status='Available' ";


$result = mysql_query($sql);