mikebyrne Posted March 16, 2009 Share Posted March 16, 2009 At present my submit button is left alligned but I'd like to have it alligned underneath my optionbox. How would I code this? <html> <style type="text/css"> label { width:150px; margin-right:5px; text-align:right; display:block; float:left; } .style1 {font-weight: bold} </style> <body> <form name="test.php" method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>"> <p><img src="untitled.jpg" alt="" width="994" height="176" /></p> <p align="left"><strong> <label for "Station">Poling Station</label> <select name="Station"> <option value="Athy Boys Nat. School - Room 01">Athy Boys Nat. School - Room 01</option> <option value="Athy Boys Nat. School - Room 02">Athy Boys Nat. School - Room 02</option> <option value="Athy Boys Nat. School - Room 03">Athy Boys Nat. School - Room 03</option> <option value="Athy Boys Nat. School - Room 04">Athy Boys Nat. School - Room 04</option> <option value="Athy Boys Nat. School - Room 05">Athy Boys Nat. School - Room 05</option> <option value="Athy Boys Nat. School - Room 06">Athy Boys Nat. School - Room 06</option> <option value="Athy Boys Nat. School - Room 07">Athy Boys Nat. School - Room 07</option> <option value="Athy Boys Nat. School - Room 08">Athy Boys Nat. School - Room 08</option> <option value="Saint Vincent's Hospital">Saint Vincent's Hospital</option> <option value="Scoil Mhichil Naofa - Room 01">Scoil Mhichil Naofa - Room 01</option> <option value="Scoil Mhichil Naofa - Room 02">Scoil Mhichil Naofa - Room 02</option> <option value="Scoil Mhichil Naofa - Room 03">Scoil Mhichil Naofa - Room 03</option> <option value="Scoil Mhichil Naofa - Room 04">Scoil Mhichil Naofa - Room 04</option> <option value="Scoil Mhichil Naofa - Room 05">Scoil Mhichil Naofa - Room 05</option> </select> </strong> <p align="left"> <input name="submit" value="Submit" type="submit" /> </p> </form> </body> </html> <? } // don't forget to close the mysql connection mysql_close(); ?> Quote Link to comment https://forums.phpfreaks.com/topic/149726-solved-alligning-submit-button-underneat-optionbox/ Share on other sites More sharing options...
grissom Posted March 16, 2009 Share Posted March 16, 2009 The easist way would be to put the various elements into a <TABLE> Or, you could use <DIV> elements to position each element on the screen to the exact pixel, but it is a bit fiddly. Personally, I'd go for the <TABLE> option. Quote Link to comment https://forums.phpfreaks.com/topic/149726-solved-alligning-submit-button-underneat-optionbox/#findComment-786254 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.