You probably want to make statistics for web pages. The most common way
to do that is to use a PHP script that outputs an image and writes to a
database some data. The code may look like this:

/** stat.php ********************/
<?
        $query = "INSERT INTO stats
                (id, remote_host, http_user_agent, http_referer, path,
query, screen)
                VALUES
                ('$tracking_id', '$REMOTE_HOST', '$HTTP_USER_AGENT', 
                        '$HTTP_REFERER', '$URI[path]', '$URI[query]',
'$scr')";
        $result = @pg_exec($conn, $query);
        passthru('cat stat.png');
?>

/** any_file.html ***************/
<script language="JavaScript">
<!--
scr = screen.width + 'x' + screen.height;
document.write('<img src="stat.php?screen=' + scr + '">');
//-->
</script>


> -----Original Message-----
> From: Romeo Manzur [mailto:[EMAIL PROTECTED]]
> Sent: 5 iulie 2001 22:12
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] $phpvar = javascriptvar???
> 
> 
> I want to store the value of screen.ColorDepth on a php var...
> Thanks...
> 
> Kurt Lieber wrote:
> 
> > As the original respondent said:
> >
> > window.location = 'http://url?yourVar=' + yourVar;
> >
> > from there, parse out the URL variable and store it into a 
> PHP variable and
> > you're good to go.
> > ----- Original Message -----
> > From: "Romeo Manzur" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Thursday, July 05, 2001 11:55 AM
> > Subject: [PHP] $phpvar = javascriptvar???
> >
> > > what I mean is, how could I save a javascript var value 
> on a php var???
> > > Thanks...
> > >
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > To contact the list administrators, e-mail: 
> [EMAIL PROTECTED]
> > >
> > >
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: 
> [EMAIL PROTECTED]
> 
> 

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to