DragonPrime - LoGD Resource Community
Welcome Guest
  • Good morning, Guest.
    Please log in, or register.
  • January 20, 2019, 09:16:13 AM
Home Forums News Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Resource Pages

Pages: [1]   Go Down
Author Topic: getting my site out of referers  (Read 2422 times)
0 Members and 1 Guest are viewing this topic.
Mod God
Offline Offline

Posts: 1916

View Profile WWW
« on: April 28, 2004, 08:35:46 PM »

some players are using the url without the "www" and every page they go to is coming up under referrals.  

first off, maybe a suggestion to Ken, support for multiple sites to be listed, because i have a few different domain names, just people only play the game on 1.

perhaps there is something i can do outside of the game, .htaccess maybe?

« Reply #1 on: April 29, 2004, 04:38:47 AM »

I had a similar problem....

in common.php find
   $site = substr($site,0,strpos($site,"/"));

now note the first line and last bracket....
in the first line make sure you change yourip to your ip....
the rest of the code is the original... I just included if here so you could see where the line and bracket should be placed....
   if (strstr($site, $_SERVER['SERVER_NAME']) =="" and (strstr($site,"yourip") =="")){
   if ($row['refererid']>""){
      $sql = "UPDATE referers SET count=count+1,last=now(),site='".addslashes($site)."' WHERE refererid='{$row['refererid']}'";
      $sql = "INSERT INTO referers (uri,count,last,site) VALUES ('{$_SERVER['HTTP_REFERER']}',1,now(),'".addslashes($site)."')";

Even with this I still empty my reffers table about once a week as it still seems to get rather large.... but this will trim out all hits from within your site....
Pages: [1]   Go Up
Jump to:  

DragonPrime Notices
Please take the time to read the FAQ and browse the DragonPedia

Support Us
No funds raised yet this year
Your help is greatly appreciated!
Recent Topics
DragonPrime LoGD
Who's Online
44 Guests, 0 Users
Home Forums News Downloads Login Register Advanced Search