Forum Moderators: not2easy

Message Too Old, No Replies

tripping hasLayout - display:block after display:inline-block;

hasLayout reset

         

vsgill

8:39 pm on Feb 23, 2008 (gmt 0)

10+ Year Member



Hello Friends
I am having problem setting haslayout for ie on an <a> tag.

If i display:inline-block; to the anchor is works...
but i want to reset the display to "block" after the haslayout is set to true.

so i do the following


div.advert a{
display:inline-block;
display:block;
}

but it does not set the haslayout to true.

if i do this


div.advert a{
display:inline-block;
}

its works.... but i want to set the display back to "block"

i thought once the haslayout is set to true it can not be set to false. so the above solution should work?.... but it doesn't..

Has anyone else had this problem before?

Thanks
Vik

SuzyUK

8:50 pm on Feb 23, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi vik.. the "tripswitch" only works if the rules are given separately

so:

div.advert a{
display:inline-block;
display:block;
}

needs written like:

div.advert a{
display:inline-block;
}

div.advert a{
display:block;
}

Oh and afaik, inline-block is the only hasLayout property that works to "reset"

[edited by: SuzyUK at 8:51 pm (utc) on Feb. 23, 2008]

vsgill

9:13 pm on Feb 23, 2008 (gmt 0)

10+ Year Member



thanks Suzy
That worked perfect.
Vik