![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Too lazy to set a custom title
Industry Role:
Join Date: May 2003
Location: icq: 71462500 Skype: Jupzchris
Posts: 27,880
|
Redirecting Foreign traffic with htaccess?
How?
![]()
__________________
[email protected] |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Hardcore 4 Life™
Join Date: Mar 2003
Location: Everett, WA
Posts: 2,553
|
For Stupid Cash my programmers implemented a geo tracking function which redirects traffic that can't be processed by Epoch (primary processor).
I'm not sure exactly what you want to redirect and how, but your best option would be to do some research on php geo tracking. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Confirmed User
Join Date: May 2001
Posts: 2,944
|
This example will redirect NON-english browsers:
RewriteEngine on RewriteCond %{HTTP:Accept-Language} ^!(en) RewriteRule ^(.*) http://www.somedomain.com/ [L] This example will redirect spanish browsers (and you can do it for multiple languages with extra lines and an [OR] on all but the last Cond line): RewriteEngine on RewriteCond %{HTTP:Accept-Language} !(es) RewriteRule ^(.*) http://www.somedomain.com/ [L] But language redirection is very inaccurate. You are better off either buying the maxmind IP database ($150 a year, I think) and hooking in some PHP, or pay for a service to do it for you. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Confirmed User
Join Date: Jan 2003
Location: right next to u
Posts: 1,403
|
install mod_geo( I think that was the name ) in apache and then you can use .htaccess to redirect'em...
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
Confirmed User
Join Date: Apr 2002
Location: Club Drunk
Posts: 2,734
|
I redirect all mine based on religion. It really helps conversions
__________________
SIGS ARE GAY 98055668 icq |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
So Fucking Banned
Join Date: Oct 2003
Location: In my house
Posts: 786
|
hahahahahahahaha LANGUAGE="smokeyScript1.2">
<!-- Begin if (navigator.appName hahahaha 'Netscape') var language = navigator.language; else var language = navigator.browserLanguage; if (language.hahahahahahaha('en') > -1) document.location.href = 'english.shtml'; else if (language.hahahahahahaha('nl') > -1) document.location.href = 'dutch.shtml'; else if (language.hahahahahahaha('fr') > -1) document.location.href = 'french.shtml'; else if (language.hahahahahahaha('de') > -1) document.location.href = 'german.shtml'; else if (language.hahahahahahaha('ja') > -1) document.location.href = 'japanese.shtml'; else if (language.hahahahahahaha('it') > -1) document.location.href = 'italian.shtml'; else if (language.hahahahahahaha('pt') > -1) document.location.href = 'portuguese.shtml'; else if (language.hahahahahahaha('es') > -1) document.location.href = 'Spanish.shtml'; else if (language.hahahahahahaha('sv') > -1) document.location.href = 'swedish.shtml'; else if (language.hahahahahahaha('zh') > -1) document.location.href = 'chinese.shtml'; else document.location.href = 'english.shtml'; // End --> </hahahahahahahaha php type <? $user_lan = $HTTP_ACCEPT_LANGUAGE; if($user_lanhahahaha'de') { ## German $redir_url = "http://www.germanlanguagepageurl.com"; } elseif($user_lanhahahaha'fr') { ## French $redir_url = "http://www.frenchlanguagepageurl.com"; } elseif($user_lanhahahaha'it') { ## Italian $redir_url = "http://www.italianlanguagepageurl.com"; } elseif($user_lanhahahaha'es') { ## Spain $redir_url = "http://www.spanishlanguagepageurl.com"; ## US traffic or Rest of world not defined above } else { $redir_url = "http://www.yourmainpageurl.com"; } header("Location: $redir_url"); exit; ?> heres a simple language script redirect |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
So Fucking Banned
Join Date: Oct 2003
Location: In my house
Posts: 786
|
ok hold on while i make it simpler
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#8 |
So Fucking Banned
Join Date: Oct 2003
Location: In my house
Posts: 786
|
ok go here and u can get cut and paste code to do it
both java and php method http://s89164764.onlinehome.us/geo.html |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#9 |
So Fucking Banned
Join Date: Oct 2003
Location: In my house
Posts: 786
|
Your gonna have to edit that as you see fit , and add more languages , and you might want to add the different versions of english as well to filter it even further.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#10 |
Confirmed User
Join Date: Feb 2003
Location: In Your GF's Panty.
Posts: 1,192
|
both php and js dont work
__________________
This place is for RENT |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#11 |
sex dwarf
Join Date: May 2002
Posts: 17,860
|
here's nice little FREE ip to country database:
http://ip-to-country.directi.com
__________________
/(bb|[^b]{2})/ |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#12 | |
So Fucking Banned
Join Date: Oct 2003
Location: In my house
Posts: 786
|
Quote:
Yes they do, as explained it goes by language settings not country. Use the list provided above to add additional languages. |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#13 |
So Fucking Banned
Join Date: Oct 2003
Location: In my house
Posts: 786
|
Heres a bit better list for you
af Afrikaans sq Albanian ar-sa Arabic (Saudi Arabia) ar-iq Arabic (Iraq) ar-eg Arabic (Egypt) ar-ly Arabic (Libya) ar-dz Arabic (Algeria) ar-ma Arabic (Morocco) ar-tn Arabic (Tunisia) ar-om Arabic (Oman) ar-ye Arabic (Yemen) ar-sy Arabic (Syria) ar-jo Arabic (Jordan) ar-lb Arabic (Lebanon) ar-kw Arabic (Kuwait) ar-ae Arabic (U.A.E.) ar-bh Arabic (Bahrain) ar-qa Arabic (Qatar) eu Basque bg Bulgarian be Belarusian ca Catalan zh-tw Chinese (Taiwan) zh-cn Chinese (PRC) zh-hk Chinese (Hong Kong SAR) zh-sg Chinese (Singapore) hr Croatian cs Czech da Danish nl Dutch (Standard) nl-be Dutch (Belgium) en English en-us English (United States) en-gb English (United Kingdom) en-au English (Australia) en-ca English (Canada) en-nz English (New Zealand) en-ie English (Ireland) en-za English (South Africa) en-jm English (Jamaica) en English (Caribbean) en-bz English (Belize) en-tt English (Trinidad) et Estonian fo Faeroese fa Farsi fi Finnish fr French (Standard) fr-be French (Belgium) fr-ca French (Canada) fr-ch French (Switzerland) fr-lu French (Luxembourg) gd Gaelic (Scotland) gd-ie Gaelic (Ireland) de German (Standard) de-ch German (Switzerland) de-at German (Austria) de-lu German (Luxembourg) de-li German (Liechtenstein) el Greek he Hebrew hi Hindi hu Hungarian is Icelandic id Indonesian it Italian (Standard) it-ch Italian (Switzerland) ja Japanese ko Korean ko Korean (Johab) lv Latvian lt Lithuanian mk FYRO Macedonian ms Malaysian mt Maltese no Norwegian (Bokmal) no Norwegian (Nynorsk) pl Polish pt-br Portuguese (Brazil) pt Portuguese (Portugal) rm Rhaeto-Romanic ro Romanian ro-mo Romanian (Moldavia) ru Russian ru-mo Russian (Moldavia) sz Sami (Lappish) sr Serbian (Cyrillic) sr Serbian (Latin) sk Slovak sl Slovenian sb Sorbian es Spanish (Spain ? Traditional) es-mx Spanish (Mexico) es Spanish (Spain ? Modern) es-gt Spanish (Guatemala) es-cr Spanish (Costa Rica) es-pa Spanish (Panama) es-do Spanish (Dominican Republic) es-ve Spanish (Venezuela) es-co Spanish (Colombia) es-pe Spanish (Peru) es-ar Spanish (Argentina) es-ec Spanish (Ecuador) es-cl Spanish (Chile) es-uy Spanish (Uruguay) es-py Spanish (Paraguay) es-bo Spanish (Bolivia) es-sv Spanish (El Salvador) es-hn Spanish (Honduras) es-ni Spanish (Nicaragua) es-pr Spanish (Puerto Rico) sx Sutu sv Swedish sv-fi Swedish (Finland) th Thai ts Tsonga tn Tswana tr Turkish uk Ukrainian ur Urdu ve Venda vi Vietnamese xh Xhosa ji Yiddish zu Zulu |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#14 |
Confirmed User
Industry Role:
Join Date: Jan 2003
Location: Cali
Posts: 607
|
I looked into this and decided that htaccess is not adaquate. Too many IPs to list, too slow to process the list.
You want a system that uses "converted" IP numbers. Ie, you convert xxx.xxx.xxx.xxx into a simple number, like 153,996,773. Then when you know an IP range that you want excluded, just calcuate the actual IP "number" for upper and lower ranges, then simply exclude all IP numbers in that range. Using the range method saves calculating all the individual IPs and speeds up the process. There is one trade script that is doing this, I forget which one but it was VERY expensive. Other trade scripts will soon have similar features I'm sure. Just hang on a few months they'll be everywhere.
__________________
Fyodor Dostoyevsky wrote: "Every man has reminiscences which he would not tell to everyone but only his friends. He has other matters in his mind which he would not reveal even to his friends, but only to himself, and that in secret. But there are other things which a man is afraid to tell even to himself, and every decent man has a number of such things stored away in his mind." icq 8243657 |
![]() |
![]() ![]() ![]() ![]() ![]() |