jquery - CSS max-width: 100% for IE 6 with expression? -



jquery - CSS max-width: 100% for IE 6 with expression? -

i have css:

.container img { max-width: 100% !important; height: auto; }

now need working ie 6.

i know can do:

width: expression(this.width > xxx ? xx : true);

but xxx needs number, not percentage believe.

i'm doing max-width: 100% width of image not exceed width of .container

any ideas?

thanks.

without having tested it, guess need compare elements (client) width parent's. like:

width: expression(this.clientwidth > this.parentnode.clientwidth ? this.parentnode.clientwidth + "px" : this.clientwidth + "px");

jquery internet-explorer-6 css

Comments

Popular posts from this blog

java - How to pass parameters between Request-Scoped Controllers? -

actionscript 3 - Flex: moving a point with rotation doesnt change the point XY? -

ms access - C# - Using OleDbParameter on table name -