Hello, the dropdown menu populated from the database shown below, selecting and submitting works for regions that do not have spaces in the name e.g. Scotland will work but Tyne and Wear will not.
Can someone please say if it is the query causing the problem or if it there is anything else it might be.
The dropdown displays fine but there is no luck when searching for counties with spaces.
Thanks anyone
$dealer_list = $connector->query("SELECT DISTINCT dealer_region FROM dealers ORDER BY dealer_region");
echo "<form name='dropdown_region' method='POST'>";
echo "<select name='county' value=''>County</option>";
while($county = mysql_fetch_array($dealer_list))
{//Array or records stored in $nt
echo "<option value=".$county['dealer_region'].">".ucwords(strtolower($county[dealer_region]))."</option>";
/* Option values are added by looping through the array */
}
echo "</select>";