Hi Guys
I have this little security script, which doesn't work. Everything should be fine so I really can't see the problem.
Here's my script:
<!-- Below is danish tekst -->
Din IP: <?php echo $_SERVER["REMOTE_ADDR"]; ?> er blevet registreret.<br />
Gentagne forsøg på at bryde ind i systemet vil blive anmeldt til politiet.<br /><br />
Your IP: <?php echo $_SERVER["REMOTE_ADDR"]; ?> has been noticed. <br />
Further attempts to break into the system will be reported to the authorities.
<?php
$ip = $_SERVER['REMOTE_ADDR'];
$dato = date("H:i d/m-y");
$fil = $_SERVER['PHP_SELF'];
include('config.php');
con_db();
mysql_query ("INSERT INTO indbrud (ip,dato,fil) VALUES ('$ip','$dato','$fil')");
?>
config.php is a connect-to-mysql script, where con_db() is a function decleared in the same script. That script has been copy-pasted from my other scripts, so I know that it isn't the problem.
The problem is that it doesn't register the log in my MySQL db.
Hope someone of you can see the problem
Best Regards
Christian S.