Filling Select list from MySQL in Netscape

Greetings,

I have a page with a select list that’s filled by a query I pass into it from two different pages (one is an image map, the other a series of checkboxes and select lists to set up an attribute query). The “MyTrail” select list works fine in IE and Safari, but in Netscape the resulting list has nothing in it. Is there a Netscape specific workaround for this situation or have I done something wrong?

Thanks,

-Steve

Here’s the php code for the page:

<? $order = "ORDER BY TrailName"; $query = ""; if (strlen($_POST['County']) > 0) { $query = "AND County = '" . $_POST['County'] . "' ";} if (strlen($_POST['NearestCommunity']) > 0) { $query = $query . "AND NearestCommunity LIKE '%" . $_POST['NearestCommunity'] . "%' ";} if (isset($_POST['Hiking'])) { $query = $query . "AND Hiking = 1 ";} if (isset($_POST['ADA'])) { $query = $query . "AND ADA = 1 ";} if (isset($_POST['MtnBike'])) { $query = $query . "AND MtnBike = 1 ";} if (isset($_POST['RoadBike'])) { $query = $query . "AND RoadBike = 1 ";} if (isset($_POST['Horse'])) { $query = $query . "AND Horse = 1 ";} if (isset($_POST['Equestrian'])) { $query = $query . "AND Equestrian = 1 ";} if (isset($_POST['Interpret'])) { $query = $query . "AND Interpret = 1 ";} if (isset($_POST['CCSki'])) { $query = $query . "AND CCSki = 1 ";} if ($query <> "") { $querydrop = "SELECT TrailId,TrailName FROM trails WHERE RecreationSymbols > 'A' " . $query; } else { if (!isset($MyRegion)) { $querydrop = "SELECT TrailId,TrailName FROM trails WHERE RecreationSymbols > 'A' ";} else { $querydrop = "SELECT TrailId,TrailName FROM trails WHERE Region = " . $MyRegion . " AND RecreationSymbols > 'A' ";} } $querydrop = $querydrop . $order;

$resultdrop = MYSQL_QUERY($querydrop);
$numberdrop = mysql_Numrows($resultdrop);
if ($numberdrop>0)
{
echo ‘Find a Trail Step 2: The trails in this list matched your search.  Choose one and press the “Submit” button.  Press the “Reset” button or click another section of the map to try another search.
’;
echo ‘’;
echo ‘<option="">Select One’;
$xdrop=0;
while ($xdrop<$numberdrop)
{
$TrailId = mysql_result($resultdrop,$xdrop,“TrailId”);
if ($xdrop==0) $MyTrail = $TrailId;
$TrailName = mysql_result($resultdrop,$xdrop,“TrailName”);
echo “$TrailName”;
$xdrop++;
} // end while
echo “”;
echo “
”;
} // end if
else
{ echo '

No trails matched your search!  Press the Reset button to clear the form and try another search.


'; }
?>

check your single and double quotes - IE lets some things be quoted where Mozilla (Netscape) doesn’t and vice versa.

Sponsor our Newsletter | Privacy Policy | Terms of Service