🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.comp.lang.visualbasic.ver3
Article #89

Re: screen resolution

#89
From: priv
Date: Sun, 28 Feb 1999 00:00
42 lines
2682 bytes
>
>Can anyone direct me to the serverside code used
>to detect a clients screen resolution or even better
>can any one send me a example of a script that will
>direct a user to a certain webpage depending on the
>screen resolution their using.
>
>Cheers
>
>Ryan Healey @ healey@easynet.co.uk
here U are
 function aktualRozdzielczosc ()
{
  if ( (navigator.appName == "Microsoft Internet Explorer") &&
(parseInt(navigator.appVersion) >= 4) )
    document.all ['rozdz'] . innerHTML = "   <b><big>" +
document.body.clientWidth + "x" + document.body.clientHeight + "</big></b>";

  else if ( (navigator.appName == "Netscape") &&
(parseInt(navigator.appVersion) >= 4) )
  {
    with (document["rozdz"].document)
    {
      open();
      writeln ("   <b><big>" + innerWidth + "x" + innerHeight +
"</big></b>");
      close();
    }
  }
}
in <body> write it:<body>
onResize="aktualRozdzielczosc();" onLoad="aktualRozdzielczosc();".

-------
<div class=akapit>   aktualna wielko�� okna:</div> <div style="position:
absolute" id=rozdz class=akapit>...</div>
but its only for showing same resolution
Ps: make sites in thje center of the screen then even peple who have 640x480
wont be confused:))
 f.ex table 640 for ...
it works belive
Technical Details
Message-ID: <SgfC2.13450$t71.2352263@news.tpnet.pl>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <7b4fto$84n$1@quince.news.easynet.net>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 10640d,f63b1dc3961ed237
X-Google-Attributes: gid10640d,public
X-Google-Thread: f92e3,f63b1dc3961ed237
X-Google-Attributes: gidf92e3,public
X-Google-Thread: f5713,f63b1dc3961ed237
X-Google-Attributes: gidf5713,public
X-Google-Thread: 11110c,f63b1dc3961ed237
X-Google-Attributes: gid11110c,public
X-Google-Thread: 102e3b,f63b1dc3961ed237
X-Google-Attributes: gid102e3b,public
X-Google-Thread: fdea5,f63b1dc3961ed237
X-Google-Attributes: gidfdea5,public
X-Google-Thread: 1023e1,f63b1dc3961ed237
X-Google-Attributes: gid1023e1,public
X-Google-Thread: fc48c,f63b1dc3961ed237
X-Google-Attributes: gidfc48c,public
From: "priv" <radrec@friko3.onet.pl>
Subject: Re: screen resolution
Date: 1999/02/28
Message-ID: <SgfC2.13450$t71.2352263@news.tpnet.pl>
X-Deja-AN: 449584925
References: <7b4fto$84n$1@quince.news.easynet.net>
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
X-Complaints-To: abuse@tpsa.pl
X-Trace: news.tpnet.pl 920223922 212.160.36.178 (Sun, 28 Feb 1999 18:45:22 MET DST)
Organization: Radrec Studio
NNTP-Posting-Date: Sun, 28 Feb 1999 18:45:22 MET DST
Newsgroups: alt.comp.lang.visualbasic.ver3,alt.html.editors.enhanced-html,alt.html.editors.webedit,alt.html.server-side,alt.html.tags,alt.html.writers,cz.comp.microsoft.asp,microsoft.public.frontpage.extensions.windowsnt,microsoft.public.iis4.beta.activeserve