<?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>Horn Network &#187; html</title>
	<atom:link href="http://klcin.tw/net/tag/html/feed" rel="self" type="application/rss+xml" />
	<link>http://klcin.tw/net</link>
	<description>Horn Network (.NET, ASP.NET, C#, VB.NET, JavaScript, Ubuntu, Android ...)</description>
	<lastBuildDate>Fri, 04 Mar 2011 07:25:53 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>[Google Map]我的第一張地圖</title>
		<link>http://klcin.tw/net/google-map-my-1st-map</link>
		<comments>http://klcin.tw/net/google-map-my-1st-map#comments</comments>
		<pubDate>Thu, 10 Jul 2008 09:43:53 +0000</pubDate>
		<dc:creator>klcintw</dc:creator>
				<category><![CDATA[Google Map]]></category>
		<category><![CDATA[html]]></category>

		<guid isPermaLink="false">http://klcin.tw/net/google-map%e6%88%91%e7%9a%84%e7%ac%ac%e4%b8%80%e5%bc%b5%e5%9c%b0%e5%9c%96</guid>
		<description><![CDATA[要使用Google Map你只要會一點HTML和Javascript就可以了。 申請 Google Maps API Key 如果你只是要在自己的電腦上測試可以先跳過這個步驟。 但是當你要把寫好的程式放到網站時就一定要申請不然google不給用。 申請API Key的網址：Sign Up for the Google Maps API 打勾（表示你同意Google所訂的條款）輸入你的網站URL再按「Generate API Key」就會產生專屬的key。 若使用錯誤的key會顯示「此網站上使用的Google地圖API機碼已由另一個網站註用。您可以至http://code.google.com/apis/maps/ 為此網站產生新的機碼。」 網頁編碼要用 UTF-8 &#60;meta http-equiv=&#34;content-type&#34; content=&#34;text/html; charset=utf-8&#34;/&#62; 基本程式 AJAX 版（執行範例） &#60;!DOCTYPE html PUBLIC &#34;-//W3C//DTD XHTML 1.0 Strict//EN&#34; &#34;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&#34;&#62; &#60;html xmlns=&#34;http://www.w3.org/1999/xhtml&#34;&#62; &#60;head&#62; &#60;meta http-equiv=&#34;content-type&#34; content=&#34;text/html; charset=utf-8&#34;/&#62; &#60;title&#62;Google Maps &#124; Horn Network&#60;/title&#62; &#60;script src=&#34;http://maps.google.com/jsapi?key=_KEY_&#34; type=&#34;text/javascript&#34;&#62;&#60;/script&#62; &#60;script [...]]]></description>
			<content:encoded><![CDATA[<p>要使用Google Map你只要會一點HTML和Javascript就可以了。</p>
<h2>申請 Google Maps API Key</h2>
<p>如果你只是要在自己的電腦上測試可以先跳過這個步驟。    <br />但是當你要把寫好的程式放到網站時就一定要申請不然google不給用。</p>
<p>申請API Key的網址：<a href="http://code.google.com/apis/maps/signup.html" target="_blank">Sign Up for the Google Maps API</a>     <br />打勾（表示你同意Google所訂的條款）輸入你的網站URL再按「Generate API Key」就會產生專屬的key。</p>
<p>若使用錯誤的key會顯示「此網站上使用的Google地圖API機碼已由另一個網站註用。您可以至http://code.google.com/apis/maps/ 為此網站產生新的機碼。」</p>
<h2>網頁編碼要用 UTF-8</h2>
<p><code>&lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot;/&gt;</code></p>
<p> <span id="more-10"></span><br />
<h2>基本程式</h2>
<p>AJAX 版（<a href="http://klcin.tw/ap/gmap/map00.htm" target="_blank" rel="gb_page_fs[]">執行範例</a>）</p>
<pre class="brush: html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;
  &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;
  &lt;head&gt;
    &lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot;/&gt;
    &lt;title&gt;Google Maps | Horn Network&lt;/title&gt;
    &lt;script src=&quot;http://maps.google.com/jsapi?key=_KEY_&quot;
      type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
    &lt;script type=&quot;text/javascript&quot;&gt;
    //&lt;![CDATA[
google.load(&quot;maps&quot;, &quot;2.x&quot;);
google.setOnLoadCallback(initialize);

var map = null;
function initialize() {
	// 檢查瀏覽器是否可使用 Google Map API
	if ( GBrowserIsCompatible() ) {
        map = new google.maps.Map2(document.getElementById(&#039;map&#039;));
		// 設定地圖中心點
		map.setCenter(new GLatLng(25.036772,121.520269), 12);
	} // if
	else {
		alert(&#039;您的瀏覽器不支援Google Map&#039;);
	} // else
}
    //]]&gt;
    &lt;/script&gt;
  &lt;/head&gt;
  &lt;body onunload=&quot;GUnload()&quot;&gt;
    &lt;div id=&quot;map&quot; style=&quot;width:500px; height:500px&quot;&gt;&lt;/div&gt;
&lt;small&gt;&lt;a href=&quot;http://klcin.tw/net&quot;&gt;Horn Network&lt;/a&gt;&lt;/small&gt;
  &lt;/body&gt;
&lt;/html&gt;</pre>
<p>舊版（參考：<a href="http://code.google.com/apis/maps/documentation/introduction.html#The_Hello_World_of_Google_Maps" target="_blank">The "Hello, World" of Google Maps</a>）</p>
<pre class="brush: html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;
  &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;
  &lt;head&gt;
    &lt;meta http-equiv=&quot;content-type&quot;
	  content=&quot;text/html; charset=utf-8&quot;/&gt;
    &lt;title&gt;Google Maps | Horn Network&lt;/title&gt;
    &lt;script src=&quot;http://maps.google.com/maps?file=api&amp;v=2&amp;key=_KEY_&quot;
      type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
    &lt;script type=&quot;text/javascript&quot;&gt;
    //&lt;![CDATA[
function initialize() {
	// 檢查瀏覽器是否可使用 Google Map API
	if ( GBrowserIsCompatible() ) {
        var map = new GMap2(document.getElementById(&quot;map&quot;));
		// 設定地圖中心點
		map.setCenter(new GLatLng(25.036772,121.520269), 12);
	} // if
	else {
		alert(&#039;您的瀏覽器不支援Google Map&#039;);
	} // else
}
    //]]&gt;
    &lt;/script&gt;
  &lt;/head&gt;
  &lt;body onload=&quot;initialize()&quot; onunload=&quot;GUnload()&quot;&gt;
    &lt;div id=&quot;map&quot; style=&quot;width:500px; height:500px&quot;&gt;&lt;/div&gt;
&lt;small&gt;&lt;a href=&quot;http://klcin.tw/net&quot;&gt;Horn Network&lt;/a&gt;&lt;/small&gt;
  &lt;/body&gt;
&lt;/html&gt;</pre>
<p>
<h4>延伸閱讀：</h4>
</p>
<ul>
<li><a href="http://code.google.com/apis/maps/index.html">Google Map API</a></li>
<li><a href="http://code.google.com/intl/zh-CN/apis/maps/">Google 地图 API (簡體)</a> , <a href="http://code.google.com/intl/zh-CN/apis/maps/documentation/examples/">Google 地图 API 示例 (簡體)</a></li>
<li><a href="http://blog.roodo.com/syshen/archives/347151.html">syshen&#8217;s blog:Google Maps API 簡易使用文件</a></li>
<li><a href="http://my.opera.com/ocgod/blog/show.dml/1126449">使用google maps[範例] &#8211; ocgod&#8217;s Blog &#8211; by ocgod</a></li>
<li><a href="http://blog.orz.tw/2008/03/11/280">Google Maps API運用經驗 | Kai@Orz.tw</a></li>
<li><a href="http://www.cartosoft.com/mapicons/">mapicon Factory</a> 線上產生marker圖示的服務 </li>
<li><a href="http://mapki.com/wiki/Available_Images">Available Images &#8211; Google Mapki</a> Google上其它可用的圖示 </li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://klcin.tw/net/google-map-my-1st-map/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

