Note: Don’t click. This is only a screenshot.

Google map screenshot

After reading Andy Dickinson’s post about using spreadsheets to create Google maps this morning, I couldn’t resist trying it out. All worked fine expect for the last part: actually publishing it on the site. When I pasted the Google-generated code into the write box on WordPress, it created a nice, big white space but no map. You can see a screenshot of what’s supposed to appear above.

Maybe you’ll have better luck than I did (or you may even have an answer for my woes), so here’s what I did to make my map.

1. Went to this Google page to find the recipe, following a link from Mindy McAdams at Teaching Online Journalism.

2. Created a Google spreadsheet of coffee shops near my house.

3. Got the coffee shop addresses the old-fashioned way: from the phone book. (That was the first time I’ve used the phone book in over a year.)

4. Tried several sites that promised to match addresses to latitude and longitude before settling on this one. It’s not ideal: you double click a location on a Google map and get the data, so you have to know where the locations are. (None of the first few I tried worked well on Vancouver addresses; here’s my Google search. You may have better luck.)

5. Copied and pasted the latitude and longitude into the spreadsheet.

6. Followed the directions for publishing the spreadsheet, loading it into the Google instruction page, setting the parameters for the map.

7. Got my Google-generated code and pasted it into the blog software, which is where the wheels came off.

If I can get this to work, it will be an easy and relatively quick to get a map on a site and a nice first step for getting my students into the world of mashups for journalism.

UPDATE: Interestingly, the Google code works if I save it as an html file and then launch it from my desktop. It looks like, something in WordPress is messing with the code.

TAGS: , , ,

3 Comments to “(Almost) mapping caffeine”

  1. Andy says:

    Hi Mark

    Sorry to be the cause of map related woe. :)

    There are a number of reasosn why the maps don’t display if you put the code in a post. Soemthing to do with javascript calls and the way the maps api sets the api key.

    This tutorial seems to have it all covered

    http://techrageo.us/2005/08/16.....wordpress/

    You can also get the long and lat from a standard google maps search

    The search results generate a big url as below

    http://maps.google.co.uk/maps?.....g&cd=7

    The &sll=53.766775,-2.703323 bit is the long and lat

    Happy mapping

    Andy

    Reply

  2. Mário says:

    If you are using wordpress wysiwyg editor, the code gets “jammed”, if you switch to the “code” version of the editor, then the code can be pasted “as is”, i only use the “code” editor in wordpress.

    I get the entry in my rss reader, but here i only see this:
    Warning: preg_replace(): Unknown modifier ‘/’ in /home/tamark/public_html/students/wp-content/plugins/google-hilite.php on line 107

    Warning: preg_replace(): Unknown modifier ‘r’ in /home/tamark/public_html/students/wp-content/plugins/google-hilite.php on line 105

    Reply

  3. Mark says:

    Thank you both. Now I have my assignment for the day.

    Reply

Leave a Reply

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>