GeoComments
>>> WARNING: this appears to not work with WordPress 2.0. I’ll work up a fix soon. < <<
intro
I’ve whacked together a quick WordPress plugin that integrates the comments system with a Google Map. Sites like Frappr, that allow you to create a map and invite people to put themselves on it, are all the rage these days. Frappr’s a great tool, but it’s not integrated with your own site, and the ability to customize the look and feel is limited (if not nonexistent). So, please welcome GeoComments! One scenario I envision GeoComments being used in is on a page titled something like “Reader locations”, where readers of a weblog can add themselves to the map.
Posts and Pages
GeoComments provides additional fields for the comment form on WordPress Posts or Pages that collect information from a user that can be converted into a latitude and longitude acceptable for creating a point on the map. You can see the plugin in action on this page. Due to some limitations in WordPress, the integration with the Page functionality is practically non-existent. The plugin as it is today works only with normal posts. I think all that remains to make it work with a Page is to create a new page template, but this means that it is no longer just a drop-in plugin, and instead requires tweaking of the theme.
getting it
I’m releasing GeoComments under the GPL. That should be good enough for most purposes. If you don’t like that, please let me know and I’m sure we can work something out. I’m really only choosing the GPL by default; I’m not knowledgeable enough about licenses to really care. As long as nobody steals my stuff to pass of as their own, I’m a happy camper.
subversion
The bleeding-edge stuff (and let’s face it, this thing is only within a hair’s breadth of the bleeding edge) is available in my Subversion repository. If you want to play with the most recent changes or contribute your own, this is the place to start.
the latest “released” version—1.0
(for some definition of “release”, anyway…)
If I don’t make a 1.0 release now, it’ll never get there. Version 1.1, 2.0 or 3.14159 will hopefully add Page support. Get 1.0 here. There’s a README in there that should be sufficient to get you going. If not, leave a comment!
[...] Get it while the gettin’s good at the GeoComments project page [...]
First theme I used would not display the area for entry of location, new theme…now I can see the area for location, but the map div is blank. It sizes the div, and the plugin put the js files in the head, but no map. What template files are required, comment template? post? page? or should any of this matter?
This is great.
2 Questions:
Do I need multiple Google API’s for more than 1 map on a blog?
Does every post now default to geocomments format after activiation of plugin?
You only need one Google API key for a given “base url”. In my case, I think my GMaps API key is for “http://bravo5.org/blog/”, so every WP URL under that one will work. “http://bravo5.org/myBlog/” would not work.
You enable the GeoComments on a per-post basis in the admin console. It defaults to off.
Everything appears to installed correctly. Why aren’t the comments being posted on the map?
Looks like this isn’t compatible with WP 2.0 (or 2.0.1 in your case). I’ll try to fix this in the not too distant future.
Thanks and great job man.