Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting CSS to work on a frameset in Netscape 4.7

Status
Not open for further replies.

eyorre

Programmer
Jan 24, 2002
32
GB
I am having problems trying to get a CSS to work in Netscape 4.7.

I am pulling in the stylesheet from another file (js/scripts.js) which retrieves the relevant style sheet according to the browser type. To do this I am using the following in the <head> on each page:

<script language=&quot;JavaScript&quot; type=&quot;text/javascript&quot; src=&quot;/js/scripts.js&quot;></script>

The problem is that when opening pages into the full frameset the styles are not working. However if I refresh an individual page within the frameset it will then find the stylesheet.

Is there anyway that I can get my stylesheet to work over the entire frameset in Netscape 4.7?
 
I have found an answer to my own question. I cannot understand the logic behind it but it seems to work!

If the...

<script language=&quot;JavaScript&quot; type=&quot;text/javascript&quot; src=&quot;/js/scripts.js&quot;></script>

line is NOT the first Javascript tag in the head it solves the problem. If I don't need any further Javascript within the page I just put in empty tags before it...

<script language=&quot;JavaScript&quot;></script>

Now when I open a frameset in Netscape 4.7 all of the pages within the frameset are displaying according to the CSS.

If anyone has any idea why this solves the problem I would be grateful to know!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top