[thelist] setting base font size in CSS and Netscape 4 collapsing when font sizes are changed

Roger Newbrook roger.newbrook at kmsoftware.com
Fri Jun 21 10:16:00 CDT 2002


Evolters; I have a problem! (or two)

Firstly, does anyone know a workaround for Netscape 4 trashing the
stylesheet when a user tries toincrease the font size? it picks it up again,
with increased size fonts if the page is refreshed. (so i suppose i was
hoping that i would be able to force a refresh if font size is increased).

secondly, when my pages are loaded into netscape the font is ridiculously
small. my stylesheet uses relative sizes but i was wondering how the
basefont size (i know it's a depracated tag) in the stylesheet so that the
relative sizes refer to this base font size.

does that make sense? trawled round the web trying to resolve this as i was
hoping to be able to post it as a tip, but alas no :( so below is a little
something which saved my life the other day :)

thanks in advance (as always)

roger

<tip type="netscape force refresh on browser window resize script">

Netscape 4 drops any attached stylesheet if the browser window is resized,
to get around this, include the following script which forces a reload if
the window size changes:

if (document.layers) { onresize = reloadPage; }

if (document.layers) {
	origWidth = innerWidth;
	origHeight = innerHeight;
}

function reloadPage() {
 if ((innerWidth != origWidth) || (innerHeight != origHeight)) {
location.reload(); }
}

</tip>



More information about the thelist mailing list