HTML CSS examples for CSS Form:Form
Centering a form without using width
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> body {<!--from w w w .j a v a2s .c o m--> text-align:center } form { display:inline-block; background-color:Chartreuse; padding:11px; } </style> </head> <body> <form> <input type="text"> <input type="submit" value="submit"> </form> </body> </html>