Greenguy's Board

Greenguy's Board (http://www.greenguysboard.com/board/index.php)
-   Programming & Scripting (http://www.greenguysboard.com/board/forumdisplay.php?f=15)
-   -   php hitbot detection (http://www.greenguysboard.com/board/showthread.php?t=32177)

flashingfrank 2006-06-12 02:24 PM

php hitbot detection
 
i have a little php problem.

i just put some hitbot detection script on my tgp, but i cant get it to work right.

i inserted a couple of links on my index page with the following code:

PHP Code:

<a href="http://domain.com/a/go.php?from=<? echo $_SERVER['HTTP_REFERER']; ?>
class="proxy">free anal movies</a>

the link leads to go.php that has the following code:
PHP Code:

<? 
mail
("proxy@domain.com""Hitbot:""From: $from\r\n"); 
?>

the variable is passed on to the go.php file, and the sending of the email is working fine, but the referer variable is not inserted in the mail.

anyone knows why it does not work?

matt 2006-06-13 03:17 AM

A couple of things i noticed at a glance...

Maybe this:



Should be




Or possibly this:

mail("proxy@domain.com", "Hitbot:", "From: $from\r\n");

should be

mail("proxy@domain.com", "Hitbot:", "From: " . $_GET['from'] . "\r\n");


How do you know the variable is being passed to the go.php file?

kaktusan 2006-06-13 05:37 AM

as matt said:
only the mail("proxy@domain.com", "Hitbot:", "From: " . $_GET['from'] . "\r\n");

should fix the problem i think, if your server does not support register_globals in the php, otherwise it should work fine..

flashingfrank 2006-06-13 07:30 AM

thanks guys!
i changed the mail code and it works fine now :D


All times are GMT -4. The time now is 02:07 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
© Greenguy Marketing Inc