GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Looking for Geo IP redirect script (https://gfy.com/showthread.php?t=834504)

elron 06-12-2008 04:45 PM

Looking for Geo IP redirect script
 
In other words a script that can help me redirect traffic according to countries .

Post links if u have , thanks

GrouchyAdmin 06-12-2008 05:21 PM

Plenty here

elron 06-13-2008 02:55 AM

Quote:

Originally Posted by elron (Post 14311213)
In other words a script that can help me redirect traffic according to countries .

Post links if u have , thanks

The script there seems to be analytic one and can't be used to manage traffic .

Any others ?

Turboface 06-13-2008 03:03 AM

My favorite script right now is Power Redirector
  • Redirect based on keyword.
  • Redirect based on phrases.
  • Redirect based on ip address.
  • Redirect based on referrer.
  • Redirection based on transparent proxies.
  • Redirection based on anonymous proxy.
  • Redirection based on country.
  • Redirection based on user-agents.
  • Install site-wide or per-page.
  • 301 redirects (search engine friendly).
  • Free daily updated ip-to-country database.

:thumbsup

Adultnet 06-13-2008 03:24 AM

Hi mate, if you are still looking ..
hit me up on ICQ have a good version custom coded by me :)
icq 502189

elron 06-13-2008 03:55 AM

Looks like Power Redirector seems to be what i was looking for , thanks .

elron 06-14-2008 09:45 AM

I've bought Power Redirector and it looks like im gonna cancel the transaction , it works fine if u need to redirect just one or two countries , but if u have like 30 (in my case) it hits the sql DB 30 times and searches over the entire ip list each time , and that causes serious SQL overload .

Anyone can recommend on others ?

GrouchyAdmin 06-14-2008 09:53 AM

Quote:

Originally Posted by elron (Post 14319419)
I've bought Power Redirector and it looks like im gonna cancel the transaction , it works fine if u need to redirect just one or two countries , but if u have like 30 (in my case) it hits the sql DB 30 times and searches over the entire ip list each time , and that causes serious SQL overload .

Haha. Wow.

This is the problem you find when people who aren't very seasoned decide to make software, and design it entirely wrong. The smartest move would be to convert the dotted quad to a long, and run a binary search on it from the prepopulated tables.

Something like:
Code:

  BinarySearch(A[0..N-1], ip) {
      low = 0
      high = N - 1
      while (low <= high) {
          mid = (low + high) / 2
      if (ip <= A[mid].EndIp) {
            if (ip >= A[mid].StartIp) {
            return true;
        } else {
            high = mid - 1;
        }
      } else {
        low = mid + 1
      }
      }
      return false
  }

Would be at least O(log n), which is going to be as good as you can do with MySQL, anyhow.

.. or, you could install mod_geoip2, and get the country code with every request, then do the world's lamest switch statement. It'd still be faster.

elron 06-14-2008 11:40 AM

There must be some others out there , post links please


All times are GMT -7. The time now is 05:33 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123