• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

URL Redirect to Country domain

 
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Friends,

When we enter the URL of any enterprise application which is getting used all over the world, it will be redirected to country domain like (www.google.co.in). How this is happening? From where they are getting the information about the country of the end users? is it from the browser request to the server or from any Web server to which the request is getting pointed.

Please post your ideas and drop a note regarding which is better to get such info in order to redirect the url.


Thanks!!!
 
lowercase baba
Posts: 13089
67
Chrome Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
They know the IP for your machine (they need this so they can send you whatever you are requesting). From that, it is not too hard to figure out a general idea of where you are.
 
Ragupathirajan Venkatesan
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

Thanks for your response. I agree that we can get the ip address of the client and from there we can get all the required details, but please consider me as fresher and post your ideas like how they are gettign the IP address from the request and how they are obtaining the locale information. Just by giving any sample or example.

I am trying to understand the back end logic rather having the assumptions.

Thanks in advance
 
Ranch Foreman
Posts: 275
jQuery Eclipse IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
All java based web servers use HTTPServletRequest to get information about the requestor and the request.
to elaborate.. a server's job is to respond to requests sent by clients.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic