-2

I have this textbox

<form action="/index.php" method="post">
    <input style="width: 450px;" name="url" type="text" /> 
    <input type="submit" value="Submit" />
</form>

I want to align it at the center. How can I do this?

Arulkumar
  • 12,966
  • 14
  • 47
  • 68

1 Answers1

1

Put the form inside a div. Style the div to align its child to center as:

<div style="text-align:center" >
   <form action="/index.php" method="post">
   <input style="width: 450px;" name="url" type="text" /> <input type="submit"      value="Submit" /></form>
</div>

Hope it helps.

Ram
  • 117
  • 6