Googleマップを画像に変換

  • /*
     * @title Googleマップを画像に変換
     * @description 今見ているGoogleマップをGoogle Static Maps APIを使った画像のURLに変換します(プロンプトされたURLをコピペして下さい・IE以外用)
     * @include http://maps.google.co.jp/maps?*
     * @license MIT License
     * @require 
     */
    (function(d,p,w,f,c,v,l,r){f=function(m,t){t=d.createEvent('MouseEvents');t.initEvent('click',true,true);m.dispatchEvent(t)};f(e('link'));c=function(i){i=e('leurl');if(!i){setTimeout(c,w);return}f(e('leclose'));v=i.value;r=p.center;l=v.match(/[?&]ll=([^&]*)/)?RegExp.$1:r.lat+','+r.lng;z=v.match(/[?&]z=([^&]*)/)?RegExp.$1:p.zoom;prompt('staticmap','http://maps.google.com/maps/api/staticmap?size=512x512&maptype=roadmap&sensor=false&markers=color:red|label:P|'+l+'&zoom='+z)};setTimeout(c,w)})(document,gHomeVPage.viewport,100)
  • Permalink
    このページへの個別リンクです。
    RAW
    書かれたコードへの直接のリンクです。
    Packed
    文字列が圧縮された書かれたコードへのリンクです。
    Userscript
    Greasemonkey 等で利用する場合の .user.js へのリンクです。
    Loader
    @require やソースコードが長い場合に多段ロードする Loader コミのコードへのリンクです。
    Metadata
    コード中にコメントで @xxx と書かれたメタデータの JSON です。

History

  1. 2010/11/08 21:58:24 - 2010-11-08
  2. 2010/11/08 21:57:52 - 2010-11-08
  3. 2010/11/08 21:54:52 - 2010-11-08