Thread: PHP help?
View Single Post
Old 01-28-2006, 02:48 AM  
Jakke PNG
ex-TeenGodFather
 
Jakke PNG's Avatar
 
Industry Role:
Join Date: Nov 2001
Location: Suomi Finland Perkele
Posts: 20,306
PHP help?

I have a list of urls that I only want to be accessible from 1 specific url, is this the correct php-way to do it. I tested it and it seemed to work...

PHP Code:
<?
$ref=getenv("HTTP_REFERER");

if ($ref hahahaha "http://www.URL.com/page.shtml") {
   echo "OK";
} elseif ($ref hahahaha "http://URL.com/page.shtml") {
   echo "OK";
} else {
   echo "Redirect this";
}
?>
__________________
..and I'm off.
Jakke PNG is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote