Yoghurt
10-14-2003, 09:02 AM
Hello there,
I am trying to make a browser/screen friendly javascript application.
I want my program to work like this:
1)program determines which browser is the user using and redirects him to specified site. (explorer vs. netscape)
2)On this site, there is a stylesheet definition (external file) and script that determines user's screen resolution and accordingly changes the stylesheet's definition.
<link rel="stylesheet" type="text/css" href="" id="style" /> is the definition.
3)The script uses this construction: style.href="aaa.css". This seems to work flawlessly in IE, but does not work in Netscape. I wonder if there is a way how to accomplish this.
(I know there is a way...make different XHTML file for each resolution, but that somehow does not attract me...)
Therefore, I was wondering if you could help me with this!
PS:sorry for English related mistakes!
I am trying to make a browser/screen friendly javascript application.
I want my program to work like this:
1)program determines which browser is the user using and redirects him to specified site. (explorer vs. netscape)
2)On this site, there is a stylesheet definition (external file) and script that determines user's screen resolution and accordingly changes the stylesheet's definition.
<link rel="stylesheet" type="text/css" href="" id="style" /> is the definition.
3)The script uses this construction: style.href="aaa.css". This seems to work flawlessly in IE, but does not work in Netscape. I wonder if there is a way how to accomplish this.
(I know there is a way...make different XHTML file for each resolution, but that somehow does not attract me...)
Therefore, I was wondering if you could help me with this!
PS:sorry for English related mistakes!