Jump to content

Archived

This topic is now archived and is closed to further replies.

ameerulislam

Country specific landing page and redirecting to it based on ips

Recommended Posts

What I'm looking for is let say if my visitor is from US the it will go to the default

 

mywebsite.com

 

if from UK

mywebsite.com/uk

 

from Bangladesh

mywebsite.com/bd

 

and so on. If i don't have specific code for certain countries traffic from those countries will just go to he default page.

 

 

I can get the ip address by

 

$_SERVER['REMOTE_ADDR'];

 

Now, I want to match it with country specific ip addresses.  By writing if else statement.

 

But I can't find any library function that contains ip list or something. Can any one advice me here.

Share this post


Link to post
Share on other sites

What you're looking for is called "Geolocation".

Though, what happens if someone from Bangladesh is visiting in the UK?

Share this post


Link to post
Share on other sites

What you're looking for is called "Geolocation".

Though, what happens if someone from Bangladesh is visiting in the UK?

 

And then?

Share this post


Link to post
Share on other sites

And then what?

This isn't 20 questions, you know, and we're not psychics either. Nor are we here to do the research or coding for you, neither are we here to give you all the answers on a silver platter. What we're here to do is to help those who're trying themselves, and give pointers on what to look for.

 

Also, I think you'll find this article enlightening.

Share this post


Link to post
Share on other sites

And then what?

This isn't 20 questions, you know, and we're not psychics either. Nor are we here to do the research or coding for you, neither are we here to give you all the answers on a silver platter. What we're here to do is to help those who're trying themselves, and give pointers on what to look for.

 

Also, I think you'll find this article enlightening.

 

Wow, hold on!!. I don't need your help. I'm not new in forums. If you think one or 2 words always helps then you are wrong.

 

I'm not asking u to code for me. I'm going to do it and I have spent a lot of hours as well. I have asked this question in other forums and met a whole let helpful people than you. You didn't really help with the word "Geo-location", I know that already.

 

It seems you are more interested in bullying noobs. That won't work with me coz I'm not a noob.

 

No need to reply further. I'm here to get a real answer, not an argument with a bully like you. My time is expensive.

Share this post


Link to post
Share on other sites

What I'm looking for is let say if my visitor is from US the it will go to the default

 

I'd kind like to know how to do that too.

Share this post


Link to post
Share on other sites

What I'm looking for is let say if my visitor is from US the it will go to the default

 

I'd kind like to know how to do that too.

 

My programmer found a way to identify ips. its on this domain temporarily. I still don't know how though. I'll update u later on floridaflatlander.

 

Share this post


Link to post
Share on other sites

@ameerulislam

ChristianF's point was to bring to your attention the need to allow users to pick their localisation.  Serving the wrong / undesired language can have adverse affects on your site.  And he was also correct in identifying geolocation as the tool you'll be needed. 

 

If you're so accustomed to forums - and logic forums to boot - you know that you'll need to analyze a reply...

Share this post


Link to post
Share on other sites

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.