Right i have made this code for a stats page, so it will collect the user Ip and stuff, but i have a problem when running the srip i get a parse eror on the INSERT line or the query line, can anyone tell me whats wrong !?
[code]<?
//getting the user's IP address
$Rip=$_SERVER['REMOTE_ADDR'];
//getting the user's Port
$Rport=$_SERVER['REMOTE_PORT'];
//Getting the user's Browser (Agent)
$b=$_SERVER['HTTP_USER_AGENT'];
//getting the referries URL
$r=$_SERVER['HTTP_REFERER'];
//Put all this into a Database for later viewing:
//connect to the DB
$Connect=mysql_connect(localhost,userr,pw);
//select DB
$DB=mysql_select_db(stu3sk8r_uk_db);
//setting the query in a variable, the query, in this case it
//INSERTS to the db
$query="INSERT INTO cstats ('ip','port','browser','reffer','date') VALUES ('$Rip','$Rport','$b','$r','');
//running the actual query
mysql_query($query)
?>[/code]


