Glen Lipka schrieb:
> <div style="width: 400px; border: 1px solid red;">
> <input type="text" style="width: 100%;" />
> <textarea style="width: 100%"></textarea>
> <select style="width: 100%;">
>   <option style="">Something</option>
> </select>
> 
> </div>
>  
> The padding, margins and borders built into the textarea and input tags 
> make them go past the red border.
> So I cant line up the three fields.
>  
> Is there any way to fix this?
>  
> Sorry for the off topic.  Im just so annoyed with it.
>  
> Glen


You can reset the padding of the input tags. Still the border-width does 
not play nice with the 100% width. I ended up removing padding and 
border of the inputs, wrapping those with a span and gave the span a 
border...:

<span style="display: block; border: 1px solid #ccc;"><input type="text" 
style="border: 0; padding: 0; width: 100%;" /></span>

I don't use inline styles of course. In IE such treatment is not 
required and width 100% should work fine.


-- Klaus


_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to