Forum Moderators: open
I am trying to center align a submit button on my code. It is working fine in IE, but not in Firefox.
My code snippet is as follows:
<p align="center">
<h1 align="center"> Verification Page</h1>
<p align="center">Welcome! You will have to verify your identity through Trufina first, before accessing the website.</p>
<p align="center">Please click the submit button below to verify yourself</p>
<p align="center">
<form action="http://localhost/test/userjoin6.php" align="center">
<input align="center" name="submit" type="submit" id="submit" value="Submit" />
</form></p>
As is evident, I have tried all the tags for aligning it to the center, but still on firefox, it shows the button to the left. But it works perfectly on IE.
Any suggestions? Thanks in advance!
Try using CSS instead - style="text-align:center" for inline elements, and style="margin:0 auto" for block level elements