mattyvx Posted November 16, 2009 Share Posted November 16, 2009 I have a small problem which i've eventually found out the cause for but im not sure how to resolve it. Im using the below code which grabs a list of unique cities from my database and then places them into a drop down. When the drop down is submitted the url is set and directed to a table which uses the $GET variable "City" to display information for that city. The problem is, because im using a image as a submit button its posting the mouse co-ordinates of the click along with the City variable so the output is something like "./area/table.php?City=$city&.x=21&.y=74" I only want the city variable to display but i want to keep my image submit button.... any ideas? <form action="../area/table.php" method="get"> <fieldset> <h2><label for="town">Find Instructors in:</label></h2> <?php include "scripts/citylist.php"; echo "<select name=\"City\" style=\"width:200px;height:25px;font-size:1em;\">"; while ($city = mysql_fetch_array($result)) { echo "<option value=\"$city[0]\"> $city[0] </option>"; } echo "</select>"; ?> <input class="top10" type="image" src="images/searchnow.gif" /> </fieldset> </form> p.s. we dont like using javascript Quote Link to comment Share on other sites More sharing options...
Vebut Posted November 16, 2009 Share Posted November 16, 2009 Use css? .imageSubmit { border:0; width:Xpx; height:Xpx; background:url('') no-repeat top left; display:block; } <input type="submit" value=" " class="imageSubmit" /> Quote Link to comment Share on other sites More sharing options...
mattyvx Posted November 16, 2009 Author Share Posted November 16, 2009 good shout, im trying to overcomplicate things! Back to basics Cheers Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.