<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Learning the World &#187; Google Maps</title>
	<atom:link href="http://learningtheworld.eu/tag/google-maps/feed/" rel="self" type="application/rss+xml" />
	<link>http://learningtheworld.eu</link>
	<description></description>
	<lastBuildDate>Tue, 06 Nov 2012 00:17:33 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.9.1</generator>
	<item>
		<title>Enhanced Keyboard-accessible Google Maps</title>
		<link>http://learningtheworld.eu/2009/keyboard-accessible-google-maps/</link>
		<comments>http://learningtheworld.eu/2009/keyboard-accessible-google-maps/#comments</comments>
		<pubDate>Tue, 28 Apr 2009 19:00:28 +0000</pubDate>
		<dc:creator><![CDATA[Martin Kliehm]]></dc:creator>
				<category><![CDATA[accessibility]]></category>
		<category><![CDATA[downloads]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[API]]></category>
		<category><![CDATA[Google Maps]]></category>
		<category><![CDATA[hCard]]></category>
		<category><![CDATA[keyboard access]]></category>
		<category><![CDATA[microformats]]></category>
		<category><![CDATA[opera]]></category>
		<category><![CDATA[Patrick H. Lauke]]></category>
		<category><![CDATA[vcard]]></category>

		<guid isPermaLink="false">http://learningtheworld.eu/?p=517</guid>
		<description><![CDATA[<strong>Patrick H. Lauke</strong> wrote an excellent article about <strong>keyboard-accessible Google Maps</strong> on the Opera Developer website. Still I was able to improve it slightly when I implemented an accessible map myself. I would like to share these modifications with you.]]></description>
				<content:encoded><![CDATA[<p><a href="http://twitter.com/patrick_h_lauke">Patrick H. Lauke</a> wrote an excellent article about <a href="http://dev.opera.com/articles/view/keyboard-accessible-google-maps/">keyboard-accessible Google Maps</a> on the Opera Developer website. Still I was able to improve it slightly when I implemented an <a href="http://eafra.eu/2009/venue/">accessible map</a> myself. I would like to share these modifications with you:</p>

<ul>
<li>A <strong>link to Google Maps</strong> when JavaScript is disabled.</li>
<li>Support for the <strong><a href="http://code.google.com/apis/ajax/documentation/">Google <acronym title="Asynchronous JavaScript and XML">AJAX</acronym> <acronym title="Application Programming Interface">API</acronym> Loader</a></strong>.</li><li>Using the <strong>small map control</strong>.</li>
<li>Keyboard accessibility for <strong><em>all</em> control elements</strong> within the map.</li>
</ul>

<p>As a fallback without JavaScript&nbsp;&mdash; because people disable it, because their mobile device doesn&rsquo;t support it, or because it gets filtered by corporate proxies&nbsp;&mdash; Patrick used the little known <a href="http://code.google.com/intl/en-US/apis/maps/documentation/staticmaps/">Google Static Maps <acronym>API</acronym></a>, but for some reason he missed adding the link to Google. Here is the fix:</p>

<ol class="code" title="HTML code">
<li><code>&lt;div id=&quot;map&quot;&gt;</code></li>
<li class="indent"><code><strong>&lt;a href=&quot;http://maps.google.com/maps<span class="codeSpace">&nbsp;</span><span class="nowrap">?f=q&amp;amp;output=html</span><span class="codeSpace">&nbsp;</span><span class="nowrap">&amp;amp;q=50.110950+8.684666&quot;</span> title=&quot;Google Maps&quot;&gt;</strong></code></li>
<li class="double">&lt;img src=&quot;http://maps.google.com/staticmap?hl=en<span class="codeSpace">&nbsp;</span><span class="nowrap">&amp;amp;center=50.112267,8.678384</span><span class="codeSpace">&nbsp;</span><span class="nowrap">&amp;amp;markers=50.110950,8.684666,red</span><span class="codeSpace">&nbsp;</span><span class="nowrap">&amp;amp;zoom=15&amp;amp;size=500&#x78;300</span><span class="codeSpace">&nbsp;</span><span class="nowrap">&amp;amp;key=[Your API Key]&quot;</span> alt=&quot;City map of Frankfurt&quot; width=&quot;500&quot; height=&quot;300&quot; /&gt;</li>
<li class="indent"><code><strong>&lt;/a&gt;</strong></code></li>
<li><code>&lt;/div&gt;</code></li>
</ol>

<div>
<p><a href="http://maps.google.com/maps?f=q&amp;output=html&amp;q=50.110950757575814+8.684666901826859" title="Google Maps" id="maps-static-without-js"><img src="http://maps.google.com/staticmap?hl=de&amp;center=50.112267,8.678384&amp;markers=50.110950757575814,8.684666901826859,red&amp;zoom=15&amp;size=500x300&amp;key=ABQIAAAAiX9IUvugciHL2lvi9eAyFBSMjuiRZEUjgLWr4CdH8vZ2LQfPbhTYj1_FZwtIQquykkDMnYbZpMJHXQ" alt="City Map of Frankfurt" width="510" height="300" /></a></p>
</div>

<p>Then I changed how the map is embedded. As it seems that the <a href="http://code.google.com/apis/ajax/documentation/"><acronym>API</acronym> loader</a> is more current, I preferred that way:</p>

<ol class="code" title="HTML code">
<li><code>&lt;script type=&quot;text/javascript&quot; src=&quot;http://www.google.com/jsapi?key=[Your API Key]&quot;&gt;&lt;/script&gt;</code></li>
<li><code>&lt;script type=&quot;text/javascript&quot; src="/js/accgmap.js&quot;&gt;&lt;/script&gt;</code></li>
<li><code>&lt;script type=&quot;text/javascript&quot;&gt;</code></li>
<li class="indent"><code>google.load( &#x27;maps&#x27;, &#x27;2&#x27;, { &#x27;language&#x27; : &#x27;en&#x27; } );</code></li>
<li class="indent"><code>google.setOnLoadCallback( GMAP.initMap );</code></li>
<li><code>&lt;/script&gt;</code></li>
</ol>

<p>Using the small control elements is trivial: <code>SmallMapControl()</code>. The next thing I wanted to change was <strong>keyboard access to <em>all</em> controls</strong>, in particular for the map type, <abbr title="that is">i.e.</abbr> <code>Map&nbsp;| Satellite&nbsp;| Hybrid</code>. Patrick refers to an <code>id</code>, but I found that all relevant controls have a <code>title</code>, so I just checked for that attribute. I also dropped setting the <code>style</code> attribute in JavaScript as that belongs in the <acronym title="Cascading Style Sheets">CSS</acronym> file. His original function <code>GKeyboardPatch()</code> now looks like this (note the <code>while</code> loop for a slightly better performance):</p>

<ol class="code" title="JavaScript code">
<li><code>GKeyboardPatch: <strong>function</strong>( map ) {</code></li>
<li class="indent"><code>var</code> button, divs = map.getContainer().getElementsByTagName( &#x27;div&#x27; );</li>
<li class="indent"><code>var</code> i = 0;</li>
<li class="indent"><code>while</code> ( divs[i] ) {</li>
<li class="double"><code>if ( divs[i].getAttribute( &#x27;log&#x27; ) || ( <em>divs[i].getAttribute( &#x27;title&#x27; ) &amp;&amp; divs[i].getAttribute( &#x27;title&#x27; ) != &#x27;&#x27;</em> ) ) {</code></li>
<li class="double"><span class="indent">button = document.createElement( &#x27;button&#x27; );</span></li>
<li class="double"><span class="indent">button.setAttribute( &#x27;value&#x27;, divs[i].getAttribute( &#x27;title&#x27; ));</span></li>
<li class="double"><span class="indent">divs[i].appendChild( button );</span></li>
<li class="double"><span class="indent">if ( divs[i].getAttribute( &#x27;log&#x27; )) { <code>// only control buttons</code></span></li>
<li class="double"><code class="double">// override the IE opacity filter that Google annoyingly sets</code></li>
<li class="double"><span class="double">divs[i].style.filter = &#x27;&#x27;;</span></li>
<li class="double"><code class="double">// should really set to &#x27;transparent&#x27;</code></li>
<li class="double"><span class="double">divs[i].style.background = <span class="nowrap">&#x27;url( http://www.google.com/</span><span class="codeSpace">&nbsp;</span>intl/en_ALL/mapfiles/transparent.png )&#x27;;</span></li>
<li class="double"><span class="indent">}</span></li>
<li class="double">}</li>
<li class="double">i++;</li>
<li class="indent">}</li>
<li>}</li>
</ol>

<p>Now remember I said I&rsquo;d rather separate style and behaviour, so here are a some lines of <acronym>CSS</acronym> with the setting of <code>width</code> and <code>height</code> for the <code>#map</code> being most relevant, otherwise it will collapse:</p>

<ol class="code" title="CSS code">
<li><code>#map {</code></li>
<li class="indent">height: 300px;</li>
<li class="indent">overflow: hidden;</li>
<li class="indent">position: relative;</li>
<li class="indent">width: 500px;</li>
<li><code>}</code></li>
<li><code>#maps-static, #maps-static img {</code></li>
<li class="indent">display: block;</li>
<li><code>}</code></li>
<li><code>#map span.note {</code></li>
<li class="indent">display: none;</li>
<li><code>}</code></li>
<li><code>#map button {</code></li>
<li class="indent">background: transparent;</li>
<li class="indent">border-style: solid;</li>
<li class="indent">border-width: 0;</li>
<li class="indent">cursor: pointer;</li>
<li class="indent">height: 100%;</li>
<li class="indent">left: -2px;</li>
<li class="indent">margin: 2px;</li>
<li class="indent">overflow: hidden;</li>
<li class="indent">padding: 2px;</li>
<li class="indent">position: absolute;</li>
<li class="indent">text-indent: -100em;</li>
<li class="indent">top: -2px;</li>
<li class="indent">width: 100%;</li>
<li><code>}</code></li>
<li><code>#map a:focus, #map a:active, #map button:focus, #map button:active {</code></li>
<li class="indent">outline: 2px dashed #61bf1a;</li>
<li><code>}</code></li>
</ol>

<p>And that&rsquo;s it, thanks again to Patrick for the solid foundation I built upon. Now <a href="/examples/js/accgmap.js">download the JavaScript code</a> and try to tab through the map below.</p>

<p>Actually on the other website I extracted <strong>hCard microformats</strong> from the page as well and displayed the addresses on the map, but I was lazy and used jQuery. I thought it doesn&rsquo;t look well here mixed with Patrick&rsquo;s clean <acronym title="Document Object Model">DOM</acronym> scripting, but feel free to <a href="http://eafra.eu/2009/venue/">take it from the original website</a>.</p>

<div id="map">
<p><a href="http://maps.google.com/maps?f=q&amp;output=html&amp;q=50.110950757575814+8.684666901826859" title="Google Maps" id="maps-static"><img src="http://maps.google.com/staticmap?hl=de&amp;center=50.112267,8.678384&amp;markers=50.110950757575814,8.684666901826859,red&amp;zoom=15&amp;size=500x300&amp;key=ABQIAAAAiX9IUvugciHL2lvi9eAyFBSMjuiRZEUjgLWr4CdH8vZ2LQfPbhTYj1_FZwtIQquykkDMnYbZpMJHXQ" alt="City Map of Frankfurt" width="510" height="300" /></a></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://learningtheworld.eu/2009/keyboard-accessible-google-maps/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>The Dalai Lama and Microformats</title>
		<link>http://learningtheworld.eu/2007/dalai-lama-and-microformats/</link>
		<comments>http://learningtheworld.eu/2007/dalai-lama-and-microformats/#comments</comments>
		<pubDate>Thu, 13 Sep 2007 12:00:02 +0000</pubDate>
		<dc:creator><![CDATA[Martin Kliehm]]></dc:creator>
				<category><![CDATA[accessibility]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[web standards]]></category>
		<category><![CDATA[case study]]></category>
		<category><![CDATA[Dalai Lama]]></category>
		<category><![CDATA[Frankfurt]]></category>
		<category><![CDATA[Freunde für einen Freund]]></category>
		<category><![CDATA[friends for a friend]]></category>
		<category><![CDATA[Google Maps]]></category>
		<category><![CDATA[Hessenpark]]></category>
		<category><![CDATA[microformats]]></category>
		<category><![CDATA[print version]]></category>
		<category><![CDATA[techniques]]></category>

		<guid isPermaLink="false">http://learningtheworld.eu/2007/dalai-lama-and-microformats/</guid>
		<description><![CDATA[His Holiness the Dalai Lama visits the Hessenpark near Frankfurt on September 22, and as our agency is involved in the organization of that event, we sponsored the website <em>Friends for a Friend</em>.&#160;[&#8230;]]]></description>
				<content:encoded><![CDATA[<p class="vcard"><a href="http://www.freunde-fuer-einen-freund.de" class="url" rel="met co-worker"><img src="/wp-content/uploads/2007/09/screenshot-friends-for-a-friend.jpg" alt="Screenshot: Friends for a Friend" class="floatleft book" /></a> <strong>His Holiness the Dalai Lama</strong> visits the Hessenpark near Frankfurt on September 22. As our agency is involved in the organization of that event, we sponsored the website <a href="http://friendsforafriend.de" rel="met co-worker"><strong class="fn org">Friends for a Friend</strong></a>. We had a few guidelines concerning the color coding, also we were required to reflect the poster design, but otherwise we were free to do as we liked.</p>

<p>When designing a site for a person who is so empathic we deemed it consequential not to exclude any users. After a little debate with our designers we settled on a color scheme that fulfills most requirements for <a href="http://juicystudio.com/article/new-improved-colour-contrast-firefox-extension.php">color contrast</a>. Furthermore text is resizable, forms are labeled, the structure is semantic: in the German <a href="http://bitvtest.de">accessibility test</a> we got 98 out of 100 points.</p>

<p>There are little mashups including <strong>Google Maps</strong> and a <strong>journey planner</strong> for public transport. You can get decent <strong>print results</strong>, a customized error page, the site is <strong>language negotiated</strong> and thus loads your preferred language version automatically. Loading is extremely fast since we&rsquo;ve learned our <a href="/2007/performance-2/">performance</a> lessons, and of course <strong>everything is <a href="http://microformats.org">microformatted</a></strong>.</p>

<p>I must admit it&rsquo;s difficult to microformat &ldquo;Dalai Lama,&rdquo; because it is a role, not a name. <code><abbr title="full name">fn</abbr></code> is <em>required</em>, but the text only refers to the title and role &ldquo;His Holiness the 14th Dalai Lama.&rdquo; His monastic name is of course Tenzin Gyatso, his family name is Lhamo, and his given name Thondup, but the text doesn&rsquo;t mention any of these. I&rsquo;m afraid microformats do not properly reflect this. How do you markup &ldquo;the Pope?&rdquo; <img src="http://learningtheworld.eu/wp-includes/images/smilies/icon_wink.gif" alt=";)" class="wp-smiley" /> </p>

<p class="vcard">We used <strong>WordPress</strong> as a simple content management system with a self-written plug-in to clean up the comments template&nbsp;&mdash; the default error messages were <em>so</em> unacceptable. Alas we ended up with one installation for each language because the existing internationalization plug-ins were immature. Special credits to <a href="http://lostintranslation.com" class="fn url" rel="met colleague acquaintance">Jessica Spengler</a> for the excellent and sensitive text translation!</p>

<p>I don&rsquo;t think that modern technology and something ancient as Tibetan buddhism really contradict each other. In fact topics like sustainability, responsibility and empathy become more important in our work environment. Whenever the <a href="http://www.tibet-institut.ch/content/smd/en/"><strong>Science meets Dharma</strong></a> project would call for experienced web developers I&rsquo;m sure we would find many willing to share their knowledge with Tibetan monks and get an insight into their wisdom and philosophy in return.</p>
]]></content:encoded>
			<wfw:commentRss>http://learningtheworld.eu/2007/dalai-lama-and-microformats/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
