Forums / Setup & design / Fixed / Dynamic Width - How To ...

Fixed / Dynamic Width - How To ...

Author Message

Luis M

Thursday 25 January 2007 8:26:40 am

Hi,

I this site, ez.no, in the top-right, near the flags, exists an option: ">> Fixed width" or toggle it to "Dynamic width", how can we do it ? is it an ajax code or a "standard" way ?

Thanks,

Luis

Claudia Kosny

Sunday 28 January 2007 1:05:07 pm

Hi Luis

On the ez.no webpage there seems to be an javascript that changes some class and style information for some elements in the webpage. You don't need any ajax as you do not make a request to the server, you just change the css.
Something similar is described here: http://alistapart.com/comments/switchymclayout/ , but please read also the discussion for this article as the approach described there is far from being perfect. Still - it should give you an idea on how to tackle this problem. Of course you can always have a look at the javascript and css used on the ez.no site (be careful not to violate any copyrights though).

Claudia