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)
-   -   Do you know alot about Apache? I need answer to a question (https://gfy.com/showthread.php?t=117143)

BRISK 03-19-2003 12:00 AM

Do you know alot about Apache? I need answer to a question
 
I don't know much about Apache, but I'll describe what I'm trying to do.

I have a domain that gets traffic from search engines.

Can I do something in Apache to re-direct visitors to another URL based on their country?

I've been looking at this ---> www.maxmind.com , and it says it works with Apache using mod_geoip

I don't want to use PHP, CGI or .htaccess. These visitors are visiting pure .html pages.

These visitors are coming to my domain through lots of different .html pages, I want them to click on the link in the SE and if they're from certain countries that I choose, they will be redirected to a different URL

Is this possible?

iroc409 03-19-2003 12:12 AM

you can still use .htaccess to redirect html pages, without a password. same way with 404s and stuff. look up on google how to do that, there's all kinds of crazy stuff for that. you can even deny referring domains and such.

iroc409 03-19-2003 12:12 AM

i didn't mean referrers, although you might. you can deny ips and domains, so if a user works at microsoft, you can deny them access to your page.

BRISK 03-19-2003 12:15 AM

I don't want to use PHP, CGI or .htaccess

kevinale 03-19-2003 12:16 AM

I can help you but it is a PHP based hack. See sig. I know, "no php." is that steadfast?

BRISK 03-19-2003 12:28 AM

Surfers come to my pages from links like

http://www.mydomain.com/blah/page.html

They are clicking on URLs from search engines that end in .html not php or cgi pages.

Can Apache (using something like www.maxmind.com ) recognize the country they are from and redirect them to another URL?

kad 03-19-2003 12:44 AM

Yes, I'm 99% sure you could, although, I've never done it.

You could install the GeoIP Apache Module, and set up a redirect based in the information it provides.

I could look further into it for you if you dont get a better answer from anyone else.

Feel free to hit me up on 173229403 or kad at fakeplasticrobot.com

kevinale 03-19-2003 12:50 AM

Quote:

Originally posted by BRISK
Surfers come to my pages from links like

http://www.mydomain.com/blah/page.html

They are clicking on URLs from search engines that end in .html not php or cgi pages.

Can Apache (using something like www.maxmind.com ) recognize the country they are from and redirect them to another URL?

You could use mod_rewrite and rewrite the .html to .php thus giving you the ability to use php.

kevinale 03-19-2003 12:57 AM

Quote:

Originally posted by BRISK
Surfers come to my pages from links like

http://www.mydomain.com/blah/page.html

They are clicking on URLs from search engines that end in .html not php or cgi pages.

Can Apache (using something like www.maxmind.com ) recognize the country they are from and redirect them to another URL?


Or even better yet, you can make php parse html pages also with an AddType in the httpd.conf. And add the PHP into yout .html files.

kad 03-19-2003 12:57 AM

Quote:

Originally posted by kevinale


You could use mod_rewrite and rewrite the .html to .php thus giving you the ability to use php.

Umm, why not just add .html to the AddType line in that case? Ie:

AddType application/x-httpd-php .php .htm .html

Anyhow, this doesn't solve his problem, as he doesn't want to use php.

xerox 03-19-2003 12:58 AM

rtfm :1orglaugh

Danielle 03-19-2003 12:59 AM

Add this line to your .htaccess file.

AddType application/x-httpd-php .html

Then you can use a product like http://www.trafficassistant.com/

in .html files.

Hugs,
Danielle

myneid 03-19-2003 01:06 AM

profit plantation sets it up in a cool way that may be applicable to you. if you used a php program that would check the country and if it should redirect it would print out the hahahahahahahahahaha to redirect the page. so on the front html page you would put like hahahahahahahaha language=hahahahahahahahahaha src=http://mydomain.com/countrylookup.php></hahahahahahahaha
and so if it was us it wouldnt do anything

theres my secret solution of the day

rossiya2 03-19-2003 01:10 AM

Quote:

Originally posted by myneid
hahahahahahahahahaha to redirect the page. so on the front html page you would put like hahahahahahahaha language=hahahahahahahahahaha
A secret it remains apparently.

myneid 03-19-2003 01:13 AM

the hhahaha is
script language= java script
with no spaces in the = and java and script

rossiya2 03-19-2003 01:24 AM

I had to support multiple languages and detect dialect preferences of the surfer. The Russian Apache server can do this without additional programming. I haven't tried the vanilla Apache for such situations. But it seems that the following variable's language setting can be used with a filesmatch directive using the httpd.conf file alone:

'HTTP_USER_AGENT'

Contents of the User_Agent: header from the current request, if there is one. This is a string denoting the user agent being which is accessing the page. A typical example is: Mozilla/4.5 [en] (X11; U; Linux 2.2.9 i586). Among other things, you can use this value with get_browser() to tailor your page's output to the capabilities of the user agent.

My chatbot is http://www.cologroup.net/html/chat/frame2.html

BRISK 03-19-2003 01:38 AM

Thanks for the replies. I'm gonna try that maxmind module and see if that works

BRISK 03-19-2003 05:16 AM

Any other suggestions?

sacX 03-19-2003 06:36 AM

install mod_geoip..
then use mod_rewrite in httpd.conf for the domain you're interested in

sort of like this

RewriteEngine on
RewriteCond %{GEOIP_COUNTRY_CODE} ^US$
RewriteRule ^/$ /newlocation.html [L]

BRISK 03-19-2003 06:46 AM

cool, thanks...I'm gonna try it out and see how it works :thumbsup


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

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