Hope someone here can help me out. I have a site I am building and I need for the ability to setup a different type of structure than I have done in the past:

The site will need to have groups for different locations, and I would like to be able to determine the location of the user and take them to the nearest group by default when they visit the site. (something kinda like what craigslist does when you visit)

Anybody know where I can even start for something like this?

Thank you.

Comments

WorldFallz’s picture

It depends on what 'location' maps to, but there are several ip based location determination modules in the downloads area that might be helpful.

akael’s picture

WorldFallz,

Thank you for your reply. I have looked at a bunch of those modules, but haven't really seen anything close to what I need. They are either very old and have not been supported, or don't seem to be quite what I need.

I think I am going to just create a module for the functionality that I need, but wanted to check here first.

Let me explain a bit better:

  1. I have a few different groups setup in drupal, each one is a geographic location, lets call them cities.
  2. I want each new visitor to my site to be automatically shown the group page of the city that is closest to there location
  3. I want the user to be able to select a different location, and on each visit afterwards they will be shown the last location they viewed. (This can be only for authenticated users if need be, but would be nice to store in a cookie for non auth users.

Thanks again for your response.

WorldFallz’s picture

From what I can see, you should be able to do this with the smart_ip module and some custom code-- pull the default value of the location field from the info smart_ip provides and allow the user select something different if desired.