function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i"; for(i=0;i\"" "; code += ""; return code; } function BookmarkSite() { var url = document.location.href; var title = document.title; if (document.all) window.external.AddFavorite(url, title); else if (window.sidebar) window.sidebar.addPanel(title, url, "") } function Contact() { var url = 'http://x.azjmp.com/0BZg5?sub=dbsites'; window.open(url,'Contact'); } function GoogleMapUnload() { if(document.getElementById("map") == null) return; GUnload(); } function GoogleMapLoad() { if(document.getElementById("map") == null) return; var latitude = document.getElementById("gmap_latitude"); var longitude = document.getElementById("gmap_longitude"); var bubbleText = document.getElementById("gmap_bubble"); var address= document.getElementById("gmap_address"); var city= document.getElementById("gmap_city"); var state= document.getElementById("gmap_state"); var zip= document.getElementById("gmap_zip"); var country= document.getElementById("gmap_country"); //var found = document.getElementById("gmap_found"); if(latitude != null) latitude= latitude.value; if(longitude != null) longitude= longitude.value; if(bubbleText != null) bubbleText= bubbleText.value; if(address != null) address= address.value; if(city != null) city= city.value; if(state != null) state= state.value; if(zip != null) zip= zip.value; var search = ""; if(address != null) search += address; if(state != null) search += ", " + state; if(zip != null) search += ", " + zip; if (GBrowserIsCompatible()) { var map = new GMap2(document.getElementById("map")); map.addControl(new GSmallMapControl()); map.addControl(new GMapTypeControl()); var geocoder = new GClientGeocoder(); function showAddress(search) { found = false; geocoder.getLatLng( search, function(point) { if (!point) { //document.getElementById("gmap_found").value = false; //alert(address + " not found"); if((latitude == null && longitude == null) || latitude == "" && longitude == "") { latitude = 46.890232; longitude = -71.235352; } map.setCenter(new GLatLng(latitude, longitude), 4); document.getElementById('mapmsg').innerText = "(location not found on map)"; //document.getElementById('warning').style.visibility='visible'; } else { //document.getElementById("gmap_found").value = true; //document.getElementById('warning').style.visibility='hidden'; map.setCenter(point, 14); var marker = new GMarker(point); map.addOverlay(marker); marker.openInfoWindowHtml(bubbleText); } } ); } showAddress(search); //setTimeout("alert(document.getElementById(\"gmap_found\").value);", 5000); //We MUSt have a delay to check if the map was found. //Creates a marker at the given point with the given label //var marker = new GMarker(new GLatLng(latitude, longitude), 13); //GEvent.addListener(marker, "click", function() {marker.openInfoWindowHtml(bubbleText);}); //map.addOverlay(marker); } } function InsertRating(id) { var rating = document.getElementById('optRating').value; new ajax ('/rating.php', { postBody: 'id=' + id + "&rating=" + rating, onComplete: InsertRating_Complete}); } function InsertRating_Complete(request) { //alert (request.responseText); var div = document.getElementById('divRating'); //alert(div); div.innerHTML = "Thank you!"; } function ShowRatingForm(id) { if(GetCookie('vote_' + id) == null) { var code = '  
Your rating: 
 
'; document.write(code); } } function GetCookie(name) { var dc = document.cookie; var prefix = name + "="; var begin = dc.indexOf("; " + prefix); if (begin == -1) { begin = dc.indexOf(prefix); if (begin != 0) return null; } else { begin += 2; } var end = document.cookie.indexOf(";", begin); if (end == -1) { end = dc.length; } return unescape(dc.substring(begin + prefix.length, end)); }