[WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread Joey
Hi everyone, I want to create a function that will swap a style sheet as you resize the browser, for instance, I have two style sheets, one with settings for lower than800x600, then a style sheet for any resolution greater than800x600, but imagine if someone resized the browser from 1024x768 to

Re: [WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread Kornel Lesinski
Hi everyone, I want to create a function that will swap a style sheet as you resize the browser, for instance, I have two style sheets, one with settings for lower than800x600, then a style sheet for any resolution greater than800x600, but imagine if someone resized the browser from 1024x768 to

Re: [WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread redux
Quoting Joey Is there anyway to do this using standard code? I could use onresize but this is invalid? Any suggestions? Unless I'm mistaken, resize is still accepted as a DOM event. http://www.w3.org/TR/2000/REC-DOM-Level-2-Events-20001113/events.html No time to test, but you should be able

RE: [WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread Joey
Hi Patrick, Thanks, but when I tried to insert onresize into the body tag it told me it was invalid. Also if only CSS3 Media Queries were compatible, that suggestion was man July 2002!!! Anyway I don't want to get off-topic, does anybody has a solution for what I am trying to achieve? I had a

Re: [WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread Kornel Lesinski
Thanks, but when I tried to insert onresize into the body tag it told me it was invalid. Sure, because inline JS is a technique of Ancient Netscapers. You should use DOM to attach events. I had a look at the A List Apart style switcher, but this is only if the user clicks on a link. It

RE: [WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread Paul Novitski
At 09:34 AM 3/3/2005, Joey wrote: Thanks, but when I tried to insert onresize into the body tag it told me it was invalid. Instead of doing this: body onresize=SwapStylesheets(); do this: script language=Javascript src=SwapStylesheets.js/script /head body and in

RE: [WSG] Onresize Javascript function? Any standard equivalent?

2005-03-03 Thread Joey
You are a genius, now I can just set max-width:1024px; :D Thanks matey! Ill give it a go, and see what happens. Kornel Lesiski Wrote: It does, with a little help: http://www.doxdesk.com/software/js/minmax.html ** The discussion list for