function chg_folder_img(city, cat_id) {
	
	if (!cat_id) {
		return;
	}
	
	if (city == 'yonago') {
		var yonago = document.getElementById('folder-title');
		if (cat_id == 92) {
			yonago.className = 'topics';
			document.getElementById('sub-topics').className = 'topics_on';
		}
		else if (cat_id == 93) {
			yonago.className = 'info';
			document.getElementById('sub-info').className = 'info_on';
		}
		else if (cat_id == 94) {
			yonago.className = 'program';
			document.getElementById('sub-program').className = 'program_on';
		}
		else if (cat_id == 95) {
			yonago.className = 'shisetsu';
			document.getElementById('sub-shisetsu').className = 'shisetsu_on';
		}
		else if (cat_id == 96 || cat_id == 586) {
			yonago.className = 'guide';
			document.getElementById('sub-guide').className = 'guide_on';
		}
		else if (cat_id == 97) {
			yonago.className = 'school';
			document.getElementById('sub-school').className = 'school_on';
		}
		else if (cat_id == 98) {
			yonago.className = 'time';
			document.getElementById('sub-time').className = 'time_on';
		}
		else if (cat_id == 125 || cat_id == 126 || cat_id == 127) {
			yonago.className = 'blog';
		}
		else {
			yonago.className = '';
		}
	}
	else if (city == 'tottori') {
		var tottori = document.getElementById('folder-title');
		if (cat_id == 99) {
			tottori.className = 'topics';
			document.getElementById('sub-topics').className = 'topics_on';
		}
		else if (cat_id == 106) {
			tottori.className = 'info';
			document.getElementById('sub-info').className = 'info_on';
		}
		else if (cat_id == 107) {
			tottori.className = 'program';
			document.getElementById('sub-program').className = 'program_on';
		}
		else if (cat_id == 108) {
			tottori.className = 'shisetsu';
			document.getElementById('sub-shisetsu').className = 'shisetsu_on';
		}
		else if (cat_id == 114 || cat_id == 629) {
			tottori.className = 'guide';
			document.getElementById('sub-guide').className = 'guide_on';
		}
		else if (cat_id == 109) {
			tottori.className = 'school';
			document.getElementById('sub-school').className = 'school_on';
		}
		else if (cat_id == 110) {
			tottori.className = 'time';
			document.getElementById('sub-time').className = 'time_on';
		}
		else if (cat_id == 128 || cat_id == 129 || cat_id == 130) {
			tottori.className = 'blog';
		}
		else {
			tottori.className = '';
		}
	}
	else {
		return;
	}
}

function gmap_load(city) {
	var gmap = new GMap2(document.getElementById('gmap'));
	gmap.addControl(new GSmallMapControl());
	gmap.addControl(new GMapTypeControl());
	if (city == 'yonago') {
		gmap = init_Yonago(gmap);
	}
	else if (city == 'tottori') {
		gmap = init_Tottori(gmap);
	}
	else {
		return;
	}
}

function init_Yonago(gmap) {
	gmap.setCenter(new GLatLng(35.441056486137995, 133.34118381142616), 16);
	
	var txt = '<div style="width: 250px; line-height: 150%;">' +
						'<strong>フィットネスクラブ PAJA 米子</strong>' +
						'<div style="font-size: small;">' +
						'鳥取県米子市西福原2-1-10<br />' +
						'米子しんまち天満屋5階<br />' +
						'TEL 0859-35-1500/FAX 0859-35-2100<br />' +
						'<strong>営業時間</strong><br />' +
						'月～土/9:00～22:00(L.C 21:00)<br />' +
						'日・祝日/10:00～19:00(L.C 18:00)<br />' +
						'<strong>定休日</strong><br />' +
						'毎週火曜日<br />' +
						'<strong>駐車場</strong><br />' +
						'米子しんまち天満屋 駐車場をご利用下さい。<br />' +
						'</div></div>';
	
	var yonago = new GMarker(new GLatLng(35.441056486137995, 133.34118381142616));
	GEvent.addListener(yonago, 'click', function() {
		yonago.openInfoWindowHtml(txt);
	});

	gmap.addOverlay(yonago);
	yonago.openInfoWindowHtml(txt);
	
	return gmap;
}

function init_Tottori(gmap) {
	gmap.setCenter(new GLatLng(35.49184266092576, 134.22729447484016), 16);
	
	var txt = '<div style="width: 250px; line-height: 150%;">' +
						'<strong>フィットネスクラブ PAJA 鳥取</strong>' +
						'<div style="font-size: small;">' +
						'鳥取県鳥取市富安2丁目138-4<br />' +
						'鳥取市役所駅南庁舎6階<br />' +
						'TEL 0857-21-3861/FAX 0857-21-3862<br />' +
						'<strong>営業時間</strong><br />' +
						'月～土/9:30～22:30(L.C 22:00)<br />' +
						'日・祝日/9:30～19:00(L.C 18:30)<br />' +
						'<strong>定休日</strong><br />' +
						'毎週火曜日<br />' +
						'<strong>駐車場</strong><br />' +
						'駅南庁舎駐車場をご利用ください。<br />' +
						'</div></div>';
	
	var tottori = new GMarker(new GLatLng(35.49184266092576, 134.22729447484016));
	GEvent.addListener(tottori, 'click', function() {
		tottori.openInfoWindowHtml(txt);
	});

	gmap.addOverlay(tottori);
	tottori.openInfoWindowHtml(txt);
	
	return gmap;
}