NorthStarDA
IS-IT--Management
i am trying to write a condition and a loop. The condition is always returning false, but I know it shouldn't.
now, I know $vm_user_data[county_id] has a value because I printed it later in the page. I am a PHP beginner and I can't tell if I have done this wrong. Appreciate any help.
=========================================
I have not failed. I've just found 10,000 ways that won't work.
Thomas A. Edison
Code:
while($Row = mysql_fetch_assoc($Result))
{
if($vm_user_data[county_id] == $Row[county_id])
print "<option selected value=\"$Row[county_id]\">$Row[county_id]</option>\n";
else
print "<option value=\"$Row[county_id]\">$Row[county_id]</option>\n";
}
now, I know $vm_user_data[county_id] has a value because I printed it later in the page. I am a PHP beginner and I can't tell if I have done this wrong. Appreciate any help.
=========================================
I have not failed. I've just found 10,000 ways that won't work.
Thomas A. Edison