I'm trying to show the price in the drop down list from the following code, however it is showing the product name and not the price:
<?php
//-----------------------PROCESSOR---------------------------
$query="SELECT product_name, price FROM processor";
$result = mysql_query($query);
$options="";
echo "<select name='processor' value=''>
<option>Please Select A Processor</option>";
while($nt=mysql_fetch_array($result))
{
echo "<option value='".$nt['price']."'>".$nt['product_name']."</option>";
}
echo "</select>";
?>
Can anyone help with what I am doing wrong?
thanks in advance!