On MaxMind's site they offer a free pure PHP version of their library. It seems like using this instead of requiring a PECL extension etc. would open this module up to a lot more people who don't have that kind of flexibility to monkey around on their servers.

CommentFileSizeAuthor
#1 ad_geoip-for-wusses-382864-1.patch3.61 KBwebchick

Comments

webchick’s picture

Status: Active » Needs work
StatusFileSize
new3.61 KB

And the answer appears to be... no, not easily. ;)

The first problem is there's no geoip_db_avail() function when you go this route. If I create one manually when that function doesn't exist, something still isn't working quite right because it's not saving the country association.

Here's a very incomplete and terribly crappy patch, but possibly something to start from.

webchick’s picture

Title: Remove PECL extension/Apache module requirements? » Integrate with GeoIP API module
Status: Needs work » Active

Oooo. I just found http://drupal.org/project/geoip tonight. This is a much better idea. Basically, remove all of the stuff about checking GeoIP to see if it's installed, maintaining state, etc. and leave it to GeoIP API module to figure out. This module need only worry about the Ad -> GeoIP integration.

The only problem is that the module doesn't yet support city/region levels, which this module does. For my purposes, Country is fine-grained enough, so I'll try and get something working and post back here.

jeremy’s picture

Status: Active » Postponed (maintainer needs more info)

I'm certainly not opposed to seeing the ad_geoip module properly integrated with the geoip module. A couple potential issues:

  • As you've already pointed out, we'd lose functionality. The geoip project evidently only supports the free GeoLite Country database. Until this is solved, I do not see this being a workable solution.
  • The ad_geoip.inc code needs to talk to the GeoIP database without bootstrapping the database. If we have to bootstrap Drupal every time we want to serve an advertisement, performance will drastically suffer.

Once these two issues are solved, I'm all for moving forward with this.

webchick’s picture

Well, even though the project page says country only, http://drupal.org/node/383086 implies city support was committed, although I admit to not having looked at the code since whenever I posted that issue. :)

Might be worth a look. Also my experience with Roger is he's a very responsive maintainer who would gladly accept patches.

jeremy’s picture

Status: Postponed (maintainer needs more info) » Postponed

Great! It's not clear to me if it also supports the commercial offerings (which are more accurate). And equally important, I do not yet see a solution for my performance concerns: we need to filter/serve advertisements without bootstrapping Drupal.

I'm not opposed to this idea, but it's not a project I'm likely to take on anytime soon as what we currently have works well for my current needs. Sorry. I'm moving into a postponed state, awaiting a patch that addresses all of these concerns.