function JSONscriptRequest(fullUrl) { this.fullUrl=fullUrl; this.noCacheIE='&noCacheIE='+(new Date()).getTime(); this.headLoc=document.getElementsByTagName("head").item(0); this.scriptId='JscriptId'+JSONscriptRequest.scriptCounter++; }; JSONscriptRequest.scriptCounter=1; JSONscriptRequest.prototype.buildScriptTag=function () { this.scriptObj=document.createElement("script"); this.scriptObj.setAttribute("type", "text/javascript"); this.scriptObj.setAttribute("charset", "utf-8"); this.scriptObj.setAttribute("src", this.fullUrl+this.noCacheIE); this.scriptObj.setAttribute("id", this.scriptId); }; JSONscriptRequest.prototype.removeScriptTag=function () { this.headLoc.removeChild(this.scriptObj); }; JSONscriptRequest.prototype.addScriptTag=function () { this.headLoc.appendChild(this.scriptObj); }; /*ホテル検索データ選択*/ function display(lat,lng,range,r,gkey,page,fg){ page=1; /* if(radiocheck('searchkind')=='hotel'){ hotel(lat,lng,z,gkey,page,fg); }else if(radiocheck('searchkind')=='hot'){ hotpepper(lat,lng,range,gkey,page,fg); }else if(radiocheck('searchkind')=='gnavi'){ gnavi(lat,lng,range,gkey,page,fg); }else if(radiocheck('searchkind')=='gdo'){ gdo(lat,lng,range,gkey,page,fg); }else if(radiocheck('searchkind')=='tabelog'){ tabelog(lat,lng,range,page,fg); }else if(radiocheck('searchkind')=='rakuten'){ */ if(searchkind=='hotel'){ hotel(lat,lng,z,gkey,page,fg); }else if(searchkind=='hot'){ hotpepper(lat,lng,range,gkey,page,fg); }else if(searchkind=='gnavi'){ gnavi(lat,lng,range,gkey,page,fg); }else if(searchkind=='gdo'){ gdo(lat,lng,range,gkey,page,fg); }else if(searchkind=='tabelog'){ tabelog(lat,lng,range,page,fg); }else if(searchkind=='rakuten'){ inday=document.getElementById('year').value+'-'+keta(document.getElementById('month').value,2)+'-'+keta(document.getElementById('day').value,2); inday2=document.getElementById('year').value+'/'+keta(document.getElementById('month').value,2)+'/'+keta(document.getElementById('day').value,2); outday=nday(inday2,document.getElementById('haku').value); adnum=document.getElementById('adnum').value; max=document.getElementById('max').value; /*inday='2009-09-01';outday='2009-09-02';adnum=1;max=10000;*/ rakuten(lat,lng,range,page,inday,outday,adnum,max,fg); }else if(searchkind=='geo'){ geocording(gkey); } } /*桁あわせ*/ function keta(string,num){ string=String(string); if(string.length0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しの宿は見つかりませんでした。他の条件でお試しください
'; rc=0; } jshotel.removeScriptTag(); indicate('off'); } function hotelmarking(){ point1=new Array(); huki=new Array(); var gb; var first=1; if(rc>50){hit=50;}else{hit=rc;} for(i=0;i0 && yy[i].longitude>0){ point1=new GLatLng(yy[i].latitude,yy[i].longitude); }else{ continue; } huki ='
'; huki+=''+yy[i].y_name+'
'; huki+=yy[i].y_address+'
'; if(yy[i].photo_url){huki+='';} if(yy[i].photo_company){huki+='
写真提供'+yy[i].photo_company+'';} if(yy[i].y_exp){huki+='

'+yy[i].y_exp+'

';} huki+='【予約はこちら】
'; for(i2=0;i2'+yy[i].company[i2].name+''; } huki+='
'; if(bound){ if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } } addMarker(map,point1,huki); } }; if(bound){ var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z) bound=0; } } /*ホットペッパー検索*/ function hotpepper(lat,lng,range,gkey,page,fg){ indicate('on'); makeMap(); page0=page; if(fg){ lat0=lat;lng0=lng;range0=range;gkey0=gkey; } jsp='http://webservice.recruit.co.jp/hotpepper/gourmet/v1/?key=d98a0b8193dea8ab&format=jsonp&count=50&start='+((page-1)*50+1); if(gkey){ jsp+='&keyword='+encodeURI(gkey); bound=1; }else{ jsp+='&lat='+lat+'&lng='+lng+'&range='+range; } jshotp=new JSONscriptRequest(jsp+'&callback=hotpepperdb'); jshotp.buildScriptTag(); jshotp.addScriptTag(); } function hotpepperdb(data){ if(data.results.results_available){ yy=data.results.shop; rc=data.results.results_returned; trc=data.results.results_available; pc=Math.ceil(trc/50); hotpeppermarking(); indexmake(pc,page0,lat0,lng0,'',range0,gkey0,'hot'); if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しのお店は見つかりませんでした。他の条件でお試しください
'; rc=0; } jshotp.removeScriptTag(); indicate('off'); } function hotpeppermarking(){ point1=new Array(); huki=new Array(); var gb; var first=1; if(rc>50){hit=50;}else{hit=rc;} for(i=0;i'+yy[i].name+'
'; huki+=yy[i].address+'
'; huki+='
' huki+=''; if(bound){ if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } } addMarker(map,point1,huki); } }; if(bound){ var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z) bound=0; } } /*ぐるなび検索*/ function gnavi(lat,lng,range,gkey,page,fg){ indicate('on'); makeMap(); page0=page; if(fg){ lat0=lat;lng0=lng;range0=range;gkey0=gkey; } jsp='http://tabitsuku.com/gnavi2json.php?hit_per_page=50&offset_page='+page; if(gkey){ jsp+='&freeword='+encodeURI(gkey); bound=1; }else{ jsp+='&latitude='+lat+'&longitude='+lng+'&range='+range; } jsgnavi=new JSONscriptRequest(jsp+'&callback=gnavidb'); jsgnavi.buildScriptTag(); jsgnavi.addScriptTag(); } function gnavidb(data){ if(data.total_hit_count){ yy=data.rest; rc=data.hit_per_page; trc=data.total_hit_count; pc=Math.ceil(trc/50); gnavimarking(); indexmake(pc,page0,lat0,lng0,'',range0,gkey0,'gnavi'); if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しのお店は見つかりませんでした。他の条件でお試しください
'; rc=0; } jsgnavi.removeScriptTag(); indicate('off'); } function gnavimarking(){ point1=new Array(); huki=new Array(); var gb; var first=1; if(rc>50){hit=50;}else{hit=rc;} for(i=0;i'+yy[i].name+'
'; huki+=yy[i].address+'
'; if(yy[i].pr_short){huki+=yy[i].pr_short+'
';} huki+='
' huki+=''; if(bound){ if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } } addMarker(map,point1,huki); } }; if(bound){ var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z) bound=0; } } /*食べログ ラジオボタン選択時に文字フォームを消して、日程・人数入力を表示させる */ function tabelog(lat,lng,range,page,fg){ indicate('on'); makeMap(); page0=page; if(fg){ lat0=lat;lng0=lng;range0=range; } var trange if(range==1){ trange='small'; }else if(range<3){ trange='medium'; }else{ trange='large'; } jsp ='http://tabitsuku.com/tabelog2json.php?PageNum='+page; jsp+='&latitude='+lat+'&longitude='+lng+'&range='+trange; jstabelog=new JSONscriptRequest(jsp); jstabelog.buildScriptTag(); jstabelog.addScriptTag(); } function tabelogdb(data){ if(data.NumOfResult){ yy=data.Item; rc=data.Item.length; trc=data.NumOfResult; pc=Math.ceil(trc/20); if(pc>100){pc=100;} tabelogmarking(); indexmake(pc,page0,lat0,lng0,'',range0,'','tabelog'); if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しのお店は見つかりませんでした。他の条件でお試しください
'; rc=0; } jstabelog.removeScriptTag(); indicate('off'); } function tabelogmarking(){ point1=new Array(); huki=new Array(); var gb; var first=1; if(rc>20){hit=20;}else{hit=rc;} for(i=0;i'+yy[i].RestaurantName+'
'; huki+=yy[i].Address+'
'; /* huki+='
'; huki+='';*/ if(bound){ if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } } addMarker3(map,point1,huki,rcd) /* addMarker(map,point1,huki);*/ } }; if(bound){ var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z) bound=0; } } /*ゴルフ場検索*/ function gdo(lat,lng,range,gkey,page,fg){ indicate('on'); makeMap(); page0=page; if(fg){ lat0=lat;lng0=lng;range0=range;gkey0=gkey; } jsp='http://tabitsuku.com/gdo2json.php?page='+page; if(gkey){ bound=1; jsp+='&gkey='+encodeURI(gkey); }else{ jsp+='&lat='+lat+'&wlat='+wlat+'&lng='+lng+'&wlng='+wlng; } jsgdo=new JSONscriptRequest(jsp); jsgdo.buildScriptTag(); jsgdo.addScriptTag(); } function gdodb(data){ if(data.gdo.totalRecordCount){ rc=data.gdo.recordCount; trc=data.gdo.totalRecordCount; pc=data.gdo.pageCount; yy=data.gdo.corselist; gdomarking(); indexmake(pc,page0,lat0,lng0,'',range0,gkey0,'gdo'); if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しのゴルフコースは見つかりませんでした。他の条件でお試しください
'; rc=0; } jsgdo.removeScriptTag(); indicate('off'); } function gdomarking(){ point1=new Array(); huki=new Array(); var gb; var first=1; if(rc>50){hit=50;}else{hit=rc;} for(i=0;i'+yy[i].name+'
'; if(yy[i].photo_url){huki+='';} if(yy[i].exp){huki+='

'+yy[i].exp+'

';} huki+=''; if(bound){ if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } } addMarker(map,point1,huki); } }; if(bound){ var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z) bound=0; } } /*google検索*/ function geocording(gkey){ indicate('on'); makeMap(); gkey0=gkey; gurl='http://maps.google.co.jp/maps/geo?key=ABQIAAAAHazWPH7WRxfJ2uHuBtDfzxQu5cbn0D5FSGgZvtSo1cUKXxvZfxTy8sDKKXJ5PE_mEn7bJqtwR7jURw&q='+encodeURI(gkey)+'&output=json&ie=UTF8'; jsgeo=new JSONscriptRequest(gurl+'&callback=geo'); jsgeo.buildScriptTag(); jsgeo.addScriptTag(); } function geo(data){ if(data.Status.code==200){ yy=data.Placemark; rc=yy.length; trc=rc; pc=1; geomarking(); indexmake(pc,1,'','','','',gkey0,'geo') if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else if(!gkey0){ document.getElementById('message0').innerHTML='
キーワードを入力してください
'; rc=0; }else{ document.getElementById('message0').innerHTML='
お探しの場所はヒットしませんでした
'; rc=0; } jsgeo.removeScriptTag(); indicate('off'); } function geomarking(){ messageClear(); point1=new Array(); huki=new Array(); var gb; var first = 1; hit=rc; for(i=0;i'; if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } addMarker(map,point1,huki); } }; var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z); geoFormClear(); } /*google検索 yadolist用*/ function yadolist(gkey){ indicate('on'); makeMap(); gkey0=gkey; gurl='http://maps.google.co.jp/maps/geo?key=ABQIAAAAHazWPH7WRxfJ2uHuBtDfzxQu5cbn0D5FSGgZvtSo1cUKXxvZfxTy8sDKKXJ5PE_mEn7bJqtwR7jURw&q='+encodeURI(gkey)+'&output=json&ie=UTF8'; jsgeo=new JSONscriptRequest(gurl+'&callback=geo2'); jsgeo.buildScriptTag(); jsgeo.addScriptTag(); } function geo2(data){ if(data.Status.code==200){ yy=data.Placemark; rc=yy.length; geomarking2(); if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しの場所はヒットしませんでした
'; rc=0; } jsgeo.removeScriptTag(); indicate('off'); } function geomarking2(){ messageClear(); point1=new Array(); huki=new Array(); var gb; var first = 1; hit=rc; for(i=0;i'; if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } addMarker(map,point1,huki); } }; var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z); } /*楽天空室検索 ラジオボタン選択時に文字フォームを消して、日程・人数入力を表示させる*/ function rakuten(lat,lng,range,page,inday,outday,adnum,max,fg){ indicate('on'); makeMap(); page0=page; r=Math.round(r/100)/10; if(r>3){r=3;} if(fg){ lat0=lat;lng0=lng;range0=range;inday0=inday;outday0=outday;adnum0=adnum;max0=max; } jsp='http://api.rakuten.co.jp/rws/3.0/json?developerId=7da9c88b8995bc583e54fa384eb6e87b&operation=VacantHotelSearch&version=2009-10-20&datumType=1'; jsp+='&latitude='+lat+'&longitude='+lng+'&searchRadius='+r; jsp+='&checkinDate='+inday; jsp+='&checkoutDate='+outday; jsp+='&adultNum='+adnum; if(max){jsp+='&maxCharge='+max;} jsrakuv=new JSONscriptRequest(jsp+'&callBack=rakutendb'); jsrakuv.buildScriptTag(); jsrakuv.addScriptTag(); } function rakutendb(data){ if(data.Body.pagingInfo.recordCount){ yy=data.Body.hotel; rc=Number(data.Body.pagingInfo.last)-Number(data.Body.pagingInfo.first)+1; trc=data.Body.pagingInfo.recordCount; pc=Math.ceil(trc/30); rakutenmarking(); indexmake_raku(pc,page0,lat0,lng0,range0,inday0,outday0,adnum0,max0,'rakuten'); if(rc>0){ document.getElementById('message0').innerHTML='
地図上のマーカーをクリックすると、このウィンドウに情報が表示されます
'; } }else{ document.getElementById('message0').innerHTML='
お探しの宿は見つかりませんでした。他の条件でお試しください
'; rc=0; } jsrakuv.removeScriptTag(); indicate('off'); } function rakutenmarking(){ point1=new Array(); huki=new Array(); var gb; var first=1; if(rc>30){hit=30;}else{hit=rc;} for(i=0;i'+yy[i].hotelInfo[0].hotelBasicInfo.hotelName+'
'; huki+=yy[i].hotelInfo[0].hotelBasicInfo.address2+'
'; huki+=yy[i].hotelInfo[0].hotelBasicInfo.hotelSpecial+'
'; huki+='
' if(yy[i].roomInfo.length){ huki+='

【お部屋情報】

'; for(ii=0;ii'+yy[i].roomInfo[ii].planName+'
'; }else{ huki+=yy[i].roomInfo[ii].planName+'
'; } } if(yy[i].roomInfo[ii].roomName){huki+=yy[i].roomInfo[ii].roomName+'
';} if(yy[i].roomInfo[ii].dailyCharge.length){ for(iii=0;iii'; } } huki+='

'; } huki+=''; } huki+=''; if(bound){ if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } } addMarker(map,point1,huki); }; if(bound){ var z=map.getBoundsZoomLevel( gb ); if(z>0){z=z-1;} map.setCenter(gb.getCenter(), z) bound=0; } } function indexmake_raku(pc,page0,lat0,lng0,range0,inday0,outday0,adnum0,max0){ var index=''+page+''; js='javascript:void(0)'; for(i=1; i < 5 ; i++){ if(page-i>0){index=''+(page-i)+' '+index;}; if(Number(page)+i<=Number(pc)){index+=' '+(Number(page)+i)+'';}; }; index+=' '; if(page-1>0){index='« '+index;}; if(Number(page)+1<=Number(pc)){index+=' »';}; if(rc<2){index='';}; index+='
'; } /*インデックス生成*/ function indexmake(pc,page,lat,lng,z,range,gkey,kind){ var rows = 50; if(pc>1){ var index=''+page+''; js='javascript:void(0)'; if(kind=='hotel'){ for(i=1; i < 5 ; i++){ if(page-i>0){index=''+(page-i)+' '+index;}; if(Number(page)+i<=Number(pc)){index+=' '+(Number(page)+i)+'';}; }; index+=' '; if(page-1>0){index='« '+index;}; if(Number(page)+1<=Number(pc)){index+=' »';}; if(rc<2){index='';}; index+='
'; }else if(kind=='hot'){ for(i=1; i < 5 ; i++){ if(page-i>0){index=''+(page-i)+' '+index;}; if(Number(page)+i<=pc){index+=' '+(Number(page)+i)+'';}; }; index+=' '; if(page-1>0){index='« '+index;}; if(Number(page)+1<=pc){index+=' »';}; if(rc<2){index='';}; index+='
'; }else if(kind=='gnavi'){ for(i=1; i < 5 ; i++){ if(page-i>0){index=''+(page-i)+' '+index;}; if(Number(page)+i<=pc){index+=' '+(Number(page)+i)+'';}; }; index+=' '; if(page-1>0){index='« '+index;}; if(Number(page)+1<=pc){index+=' »';}; if(rc<2){index='';}; index+='
'; }else if(kind=='gdo'){ for(i=1; i < 5 ; i++){ if(page-i>0){index=''+(page-i)+' '+index;}; if(Number(page)+i<=pc){index+=' '+(Number(page)+i)+'';}; }; index+=' '; if(page-1>0){index='« '+index;}; if(Number(page)+1<=pc){index+=' »';}; if(rc<2){index='';}; index+='
'; }else if(kind=='tabelog'){ for(i=1; i < 5 ; i++){ if(page-i>0){index=''+(page-i)+' '+index;}; if(Number(page)+i<=pc){index+=' '+(Number(page)+i)+'';}; }; index+=' '; if(page-1>0){index='« '+index;}; if(Number(page)+1<=pc){index+=' »';}; if(rc<2){index='';}; index+='
'; rows = 20; } }else{ var index=''; } document.getElementById('index').innerHTML='
'+index+trc+'件のうち'+(rows*(page-1)+1)+'-'+(Number(hit)+rows*(page-1))+'件を表示
'; } function makeMap(){ indexClear(); clearMarker(); map.setCenter(new GLatLng(lat,lng), z); } function addMarker(m, p, text){ var marker = new GMarker(p); GEvent.addListener(marker,"click",function(){ /* marker.openInfoWindowHtml(text);*/ detail(text); }); m.addOverlay(marker); return marker; } function addMarker2(m, p, id){ var marker = new GMarker(p); GEvent.addListener(marker,"click",function(){ window.location.hash = id; }); m.addOverlay(marker); return marker; } function addMarker3(m, p, text,rcd){ var marker = new GMarker(p); GEvent.addListener(marker,"click",function(){ tabelogPicture(text,rcd); }); m.addOverlay(marker); return marker; } function tabelogPicture(text,rcd){ jsp ='http://tabitsuku.com/tabelogPicture2json.php?Rcd='+rcd; jstabelog=new JSONscriptRequest(jsp); jstabelog.buildScriptTag(); jstabelog.addScriptTag(); text0=text; } function tabelogPicturedb(data){ var pic=''; if(data.Item.length){ for(i=0;i photo by '+data.Item[i].UserName+'
';} } } text='
'+text0+'
'+pic+'
'; detail(text); } function detail(text){ document.getElementById('message0').innerHTML=text; } function radius(){ var mSize = map.getBounds(); wlng = mSize.toSpan().lng(); wlat = mSize.toSpan().lat(); r=40000*wlng/360*1000/2; r=Math.round(r); if(r<=300*1.2){ range=1; }else if(r<=500*1.2){ range=2; }else if(r<=1000*1.2){ range=3; }else if(r<=2000*1.2){ range=4; }else{ range=5; } } function pointnow(){ point=map.getCenter(); if(point){ lat=point.lat(); lng=point.lng(); } } function indexClear(){ document.getElementById('index').innerHTML=''; } function messageClear(){ document.getElementById('message0').innerHTML=''; } function clearMarker(){ map.clearOverlays(); } function remapping(){ clearMarker(); indexClear(); /* document.getElementById('message0').innerHTML='';*/ } function check(){ document.getElementById('map1').innerHTML+=jsp; } function geoFormClear(){ document.getElementById('gkey').value=''; } function radiocheck(a){ for(var i=0;i0 && lng[i]>0){ point1=new GLatLng(lat[i],lng[i]); }else{ continue; } if(first){ gb = new GLatLngBounds( point1, point1 ); first = 0; }else{ gb.extend( point1 ); } if(kind=='yadolist'){ huki = 'yado'+i; addMarker2(map,point1,huki); }else if(kind=='city'){ huki = ''; addMarker(map,point1,huki); }else if(kind=='detail'){ huki = 'yado'; addMarker2(map,point1,huki); } }; z=map.getBoundsZoomLevel( gb ); map.setCenter(gb.getCenter(), z); }; } function inputkey(kind){ if(kind == 'tabelog'){ document.getElementById('inputkeyarea').innerHTML=''; }else if(kind == 'rakuten'){ document.getElementById('inputkeyarea').innerHTML='
から

人 上限
円/泊まで'; rakuvform('year');rakuvform('month');rakuvform('day');rakuvform('haku');rakuvform('adnum');rakuvform('max'); }else{ document.getElementById('inputkeyarea').innerHTML=''; } } function rakuvform(kind){ var i; dd = new Date(); year = dd.getFullYear(); month = dd.getMonth()+1; day = dd.getDate(); if(kind=='year'){ select=document.createElement('select'); select.name=kind; select.id=kind; for(i=0;i<3;i++){ option=document.createElement('option'); option.value=year+i; option.appendChild(document.createTextNode(year+i)); /*if(1){option.selected='true';}*/ select.appendChild(option); } document.getElementById(kind+'0').appendChild(select); }else if(kind=='month'){ select=document.createElement('select'); select.name=kind; select.id=kind; for(i=1;i<=12;i++){ option=document.createElement('option'); option.value=i; option.id='mon'+i; option.appendChild(document.createTextNode(i)); if(i==month){option.selected='true';} select.appendChild(option); } document.getElementById(kind+'0').appendChild(select); }else if(kind=='day'){ select=document.createElement('select'); select.name=kind; select.id=kind; for(i=1;i<=31;i++){ option=document.createElement('option'); option.value=i; option.appendChild(document.createTextNode(i)); if(i==day){option.selected='true';} select.appendChild(option); } document.getElementById(kind+'0').appendChild(select); }else if(kind=='haku'){ select=document.createElement('select'); select.name=kind; select.id=kind; for(i=1;i<=10;i++){ option=document.createElement('option'); option.value=i; option.appendChild(document.createTextNode(i)); select.appendChild(option); } document.getElementById(kind+'0').appendChild(select); }else if(kind=='adnum'){ select=document.createElement('select'); select.name=kind; select.id=kind; for(i=1;i<=10;i++){ option=document.createElement('option'); option.value=i; option.appendChild(document.createTextNode(i)); select.appendChild(option); } document.getElementById(kind+'0').appendChild(select); }else if(kind=='max'){ document.getElementById('max0').innerHTML=''; } } /*メインルーチン*/ var map=new GMap2(document.getElementById("map")); map.addControl(new GMapTypeControl()); map.addControl(new GLargeMapControl()); map.addControl(new GOverviewMapControl()); map.addMapType(G_PHYSICAL_MAP); map.setMapType(G_NORMAL_MAP); GEvent.addListener(map, "zoomend", function(){ z = map.getZoom(); radius(); }); GEvent.addListener(map,"move",function(){ z = map.getZoom(); radius(); pointnow(); }); kensaku= new Array();kensakuName= new Array(); kensaku=["hotel","hot","gnavi","tabelog","gdo","rakuten","geo"]; kensakuName['hotel']="ホテル横断検索"; kensakuName['hot']="ホットペッパー検索"; kensakuName['gnavi']="ぐるなび検索"; kensakuName['tabelog']="食べログ検索"; kensakuName['gdo']="ゴルフ場検索"; kensakuName['rakuten']="空室検索"; kensakuName['geo']="地名検索"; function kansakuExp(searchkind){ document.getElementById('message').innerHTML=''; if(searchkind=='hotel'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、地図を見ながら、最高20社の大手旅行会社から宿・ホテルを横断検索して予約ができます。

ボタンを押すと地図上のお店を検索し表示します。地名・宿名などのキーワード検索もできます

'; }else if(searchkind=='hot'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、地図を見ながら、「ホットペッパー」のグルメ情報を全国検索して予約できます。

ボタンを押すと地図上のお店を検索し表示します。地名・店名などのキーワード検索もできます

'; }else if(searchkind=='gnavi'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、地図を見ながら、「ぐるなび」のグルメ情報を全国検索して予約できます。

ボタンを押すと地図上のお店を検索し表示します。地名・店名などのキーワード検索もできます

'; }else if(searchkind=='tabelog'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、地図を見ながら、「食べログ」のグルメ情報を全国検索できます。

ボタンを押すと地図上のお店を検索し表示します

'; }else if(searchkind=='gdo'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、地図を見ながら、全国のゴルフコース情報を検索して予約ができます。

ボタンを押すと地図上のゴルフコースを表示します。地名・コース名などのキーワード検索もできます

'; }else if(searchkind=='rakuten'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、地図を見ながら、空室情報を検索して予約できます。

ボタンを押すと地図上の空室を表示します。宿泊日時・日数・人数・宿泊金額を指定してください

'; }else if(searchkind=='geo'){ document.getElementById('message').innerHTML+='

'+kensakuName[searchkind]+'は、全国の地名を検索できます。

キーワードを入力してボタンを押すと、地図上に検索結果を表示します。

'; } } function formChange(searchkind0){ searchkind=searchkind0; kansakuExp(searchkind); document.getElementById('searchbox').innerHTML=''; document.getElementById('searchbox').innerHTML+='
'; document.getElementById('searchbox2').innerHTML=''; for(i=0;i'+kensakuName[kensaku[i]]+''; } } addSearchForm(searchkind); } function addSearchForm(searchkind){ /*共通部分*/ gkeyform='' submitform='
'; submitclearform=''; /*共通部分*/ if(searchkind=='tabelog'){ document.getElementById(searchkind+'0').innerHTML = ''+kensakuName[searchkind]+''; document.getElementById(searchkind+'0').innerHTML+= submitform+submitclearform; }else if(searchkind=='rakuten'){ document.getElementById(searchkind+'0').innerHTML = ''+kensakuName[searchkind]+'
'; document.getElementById(searchkind+'0').innerHTML+= '
から

人 上限
円/泊まで'; document.getElementById(searchkind+'0').innerHTML+= submitform+submitclearform; rakuvform('year');rakuvform('month');rakuvform('day');rakuvform('haku');rakuvform('adnum');rakuvform('max'); }else{ document.getElementById(searchkind+'0').innerHTML = ''+kensakuName[searchkind]+'
'; document.getElementById(searchkind+'0').innerHTML+= gkeyform+submitform+submitclearform; } } /*初期状態*/ formChange('hotel'); /*キーワード検索なしの場合を、最初にチェック*/ /* if(radiocheck('searchkind')=='tabelog'){ inputkey('tabelog'); } if(radiocheck('searchkind')=='rakuten'){ inputkey('rakuten'); } */