Previous Message
Next Message

Search box like in browsers toolbar

Sent by Stuart Homfray on 6 September 2005 15:03

Martin Petrov wrote:
> I don't want to position the image but to indent the text. I tried with  
> padding, but it just widens the box. .... Here is the example page:


Add the extra left padding to the #Box element and subtract that same 
value from the width:


#SearchForm #Box{
.... other declations
   padding: 0;
   padding-left: 1.1em;
   /*width: 10.2em;  your original value */
   width: 9.1em;

This works similarly in Firefox (1.0.6) and IE6 - I haven't tested 
elsewhere though... You may also want to adjust the padding value.


css-discuss [EMAIL-REMOVED]]
List wiki/FAQ --
Supported by --
Previous Message
Next Message

Message thread:

Possibly related: