Re: Screen Size detect??

From: Date: Sun, 02 Feb 2003 00:50:31 +0000
Subject: Re: Screen Size detect??
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-133941@lists.php.net to get a copy of this message
you can create a form with hidden fields like this <script language="JavaScript"> document.screendata.height.value=screen.height; document.screendata.width.value=screen.width; screendata.submit(); </script> <form method="post" action="index.php" name="screendata"> <input type="hidden" name="height"> <input type="hidden" name="width"> </form> bye "Nigel Powell" <guch@thatdog.demon.co.uk> escribió en el mensaje news:AA770E0A-3601-11D7-9762-003065E3C78A@thatdog.demon.co.uk... > > On a slight side note to this, how can you pass javascript variables to > PHP via POST? > > Newbie Powell > > On Saturday, February 1, 2003, at 12:21 PM, > php-general-digest-help@lists.php.net wrote: > > > From: "Sean Malloy" <sean@element.net.au> > > Date: Sat Feb 1, 2003 6:48:26 AM Europe/London > > To: "Dade Register" <dade49@yahoo.com>, <php-general@lists.php.net> > > Subject: RE: [PHP] Screen Size detect?? > > > > > > Create index.htm; > > > > <script language="JavaScript"> > > var width = screen.width; > > var height = screen.height; > > window.location = 'index.php?width=' + width + '&height=' + > > height; > > </script> > > > > and in index.php > > > > $width = $_GET['width']; > > $height = $_GET['height']; > > > > > > etc etc >

« previous php.general (#133941) next »