Previous Message
Next Message

Styling <form>

Sent by Ken Robinson on 22 March 2005 19:07


> IS there any way to style a form so it has a nice width that is 
relative 
> to the width of the content?  All the styles I try and the form 
expands 
> to the size of its parent container.  I'm using a background color so 
it 
> is fairly obvious.  I just want it to be a nice square with a border.

I usually use something like:

..myform {
   margin-right: auto;
   margin-left: auto;
   width: 80%;
   padding-top: 0.5em;
   padding-bottin: 0.5em;
   backgound-color: black;
   color: white;
   }

..text_inpt {
   width: 98%;
   }

Then
  <form class=myform ... >
  <input class=text_inpt ... >
 
   ... etc ...

Ken
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Possibly related: