Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Geotargeting by GeoIP integration Details »
Geotargeting by GeoIP integration
Mod Version: 1.0.2, by The M.I.P. (Member) The M.I.P. is offline
Developer Last Online: Jul 2011 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 3.5.x Rating: (0 vote - 0 average) Installs: 19
Released: 03 Feb 2006 Last Update: 03 Feb 2006 Downloads: 124
Not Supported Uses Plugins Additional Files  

This plugin uses Maxmind's GeoIP database to look up a visitor's country depending on his IP-address.
You may use this e.g. to display specific content or advertisements depending on the geographical location of your visitors.

Installation:
  1. Download geoip.inc PHP module and save it in your forum's includes/ directory.
  2. Download the latest GeoLite Country Database GeoIP.dat.gz, uncompress it (gunzip or evil ones like WinRAR) and save the uncompressed file under includes/GeoIP.dat (you can change the location of this file in your vBulletin Options).
    You should update this file once in a while.
  3. Make sure to have plugin system enabled.
  4. Install product mip-geoiptracker-1.0.xml
Usage:
Use $bbuserinfo[country] (or $vbulletin->userinfo[country]) in your code, your templates, etc.
Have a look on the plugin sources and on GeoIP PHP API if you're interested in getting infos other than the country code.

Changes:
  • 1.0.1 --> 1.0.2
    Fixed bug with geoipdatfile setting not being included in product.
  • 1.0 --> 1.0.1
    Basic caching is done using cookies.

This plugin is likely to work also with commercial versions of Maxmind GeoIP databases, which would - with minor tweaks - allow resolving a user's location down to region and even city levels.

On high-traffic sites, I recommend using GeoIP PHP extension or Apache module instead of this plain PHP code.

Please note that I don't give free support for this plugin, as the vBulletin part is too simple and the rest is code from Maxmind.

Download Now

Only licensed members can download files, Click Here for more information.

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Comments
  #2  
Old 03 Feb 2006, 11:33
AshokForums.com AshokForums.com is offline
 
Join Date: Nov 2005
Thanks.. Installed
Reply With Quote
  #3  
Old 03 Feb 2006, 11:51
TTG's Avatar
TTG TTG is offline
 
Join Date: May 2004
Looks interesting .. does it do any better than simply using this
Reply With Quote
  #4  
Old 03 Feb 2006, 12:58
Zia's Avatar
Zia Zia is offline
 
Join Date: Dec 2005
Real name: Z.R.
sounds nice...will it be a reason of heavy server load?
Reply With Quote
  #5  
Old 03 Feb 2006, 16:36
The M.I.P.'s Avatar
The M.I.P. The M.I.P. is offline
 
Join Date: Nov 2002
Originally Posted by Zia
sounds nice...will it be a reason of heavy server load?
This depends on your server. If your server is already running with high loads, you will definitely experience a loss of performance.
It's a non-intrusive plugin, so just give it a try.

The Maxmind guys basically included an option to use shared memory on Un*x machines (requires PHP with --enable-shmop), so that file i/o can be reduced and the db is kept in memory only once.
While this is a good idea in principle, its implementation is not unproblematic (e.g. because there's only a fixed shm key). So I did not use it in this plugin - but feel free to extend it.

If you need high-performance geotargeting, you'd be better off with using a different approach like GeoIP Apache module.
Reply With Quote
  #6  
Old 03 Feb 2006, 20:40
Snake's Avatar
Snake Snake is offline
 
Join Date: Mar 2005
Location: Cleveland, OH
Real name: Josh
* Aftermath installs
Reply With Quote
  #7  
Old 03 Feb 2006, 21:38
IrPr IrPr is offline
 
Join Date: Mar 2005
Real name: MoOZ
Nice one
but i could be a complete modification that shows Country code or flag is postbit(legacy) and member profile area...
Reply With Quote
  #8  
Old 04 Feb 2006, 01:09
Borimikan Borimikan is offline
 
Join Date: Apr 2005
Real name: James
where is the best place to have this on? in what template?
Reply With Quote
  #9  
Old 04 Feb 2006, 09:51
IrPr IrPr is offline
 
Join Date: Mar 2005
Real name: MoOZ
Originally Posted by Borimikan
where is the best place to have this on? in what template?
Postbit / Memberinfo
Reply With Quote
  #10  
Old 04 Feb 2006, 11:00
The M.I.P.'s Avatar
The M.I.P. The M.I.P. is offline
 
Join Date: Nov 2002
Originally Posted by IrPr
Originally Posted by Borimikan
where is the best place to have this on? in what template?
Postbit / Memberinfo
Don't forget that this plugin doesn't save its data in the users table or in a userfield. Location info is only available for a user/visitor who is currently surfing your forums.

The perfect use is to display banner ads depending on the geographic location of a visitor or to show location-specific content.

Last edited by The M.I.P.; 04 Feb 2006 at 11:04.
Reply With Quote
  #11  
Old 04 Feb 2006, 13:36
GamerJunk.net's Avatar
GamerJunk.net GamerJunk.net is offline
 
Join Date: Jan 2004
Awesome, I can't wait to play around with this.
__________________
NO
Reply With Quote
  #12  
Old 04 Feb 2006, 14:30
steven s's Avatar
steven s steven s is offline
 
Join Date: Aug 2004
Is there an example of this?
__________________
...steven
www.318ti.org
forum.nccbmwcca.org
Reply With Quote
  #13  
Old 04 Feb 2006, 15:12
Bad Bunny's Avatar
Bad Bunny Bad Bunny is offline
 
Join Date: Apr 2002
Originally Posted by 1996 328ti
Is there an example of this?
If there were an example, you would not know it, since it is unlikely you would be able to change your country to view a different set of ads.
__________________
My cat's breathe smells like cat food!
Reply With Quote
  #14  
Old 04 Feb 2006, 20:07
steven s's Avatar
steven s steven s is offline
 
Join Date: Aug 2004
Originally Posted by Bad Bunny
If there were an example, you would not know it, since it is unlikely you would be able to change your country to view a different set of ads.
I reread the description and now understands. I guess this is similar to what adsense does since I often have ads that are local.
__________________
...steven
www.318ti.org
forum.nccbmwcca.org
Reply With Quote
  #15  
Old 28 Apr 2006, 03:11
TomasDR TomasDR is offline
 
Join Date: Feb 2006
Anyone know how to include this in online.php?

I have it all set except it is grabbing the country from the first user and listing that country all the way down, it's not working for each individual user.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 14:36.

Layout Options | Width: Wide Color: