troubleshooting Question

Google Maps Click Through Not Working (again...!)

Avatar of Nico2011
Nico2011Flag for United Kingdom of Great Britain and Northern Ireland asked on
JavaScriptASP
9 Comments1 Solution453 ViewsLast Modified:
Hello,

The BigDaddy has helped me on this - a few times now... I don't know what has changed, but the map filled a text box when an icon was clicked, and it was working fine, but now it's stopped working...

Help - please ;-)

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>VillasDirect - rent a villa direct from the owner</title>
<link href="villasdirect.css" rel="stylesheet" type="text/css" />
<style type="text/css">
body {
	background-color: #E9E9E9;
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
	text-decoration:none;
	#map_canvas { height: 100% }
}
</style>

<style>
/*---- CROSS BROWSER DROPDOWN MENU ----*/
ul#nav {margin: 0 0 0 150px;}
ul.drop a { display:block; color: #fff; font-family: arial; font-size: 12px; font-weight:bold; letter-spacing: 1px; text-decoration:none; }
ul.drop, ul.drop li, ul.drop ul { list-style: none; margin: 0; padding: 0;}
ul.drop { position: relative; z-index: 597; float: left; }
ul.drop li { float: left; line-height: 0 em; text-align:left; font-weight:bold; color:#6b9fc6; vertical-align: middle; zoom: 1; padding: 5px 5px; }
ul.drop li.hover, ul.drop li:hover { position: relative; z-index: 599; cursor: default; text-decoration:underline; color:#fff;  }
ul.drop ul { visibility: hidden; position: absolute; top: 100%; left: 0; z-index: 598; width: 150px; background: #6b9fc6; }
ul.drop ul li { float: none; }
ul.drop ul ul { top: -12px; left: 100%; }
ul.drop li:hover > ul { visibility: visible }
</style>


<script>
	function ChangePic(a, b)
    {
        document.getElementById(b).src = a;
    }
</script>
<script src="js/googleanalytics.js"></script>
<script language="javascript" src="http://code.jquery.com/jquery-1.5.min.js"></script>
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>

<link href="villasdirect.css" rel="stylesheet" type="text/css" />
    <script src="JSCal2/src/js/jscal2.js"></script>
    <script src="JSCal2/src/js/lang/en.js"></script>
    <link rel="stylesheet" type="text/css" href="JSCal2/src/css/jscal2.css" />
    <link rel="stylesheet" type="text/css" href="JSCal2/src/css/border-radius.css" />
<!--include file="deps/flex.asp"-->

<!--body-->
<table width="1002" border="0" align="center" cellpadding="0" cellspacing="0" background="images/headbkg.jpg">
  <tr>
    <td height="145" valign="bottom"><table width="1002" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="275" align="center" valign="bottom"><p><a href="index.asp" title="Return to Home Page"><img src="images/villas-direct-logo.gif" width="198" height="53" alt="Villas Direct Logo" border="0"/></a></p>
          <p>&nbsp;</p></td>
        <td width="727" height="155" valign="top">
<table width="750" border="0" align="right" cellpadding="0" cellspacing="0">
                <tr>
                  <td height="29">
                  <table border="0" align="right" cellpadding="0" cellspacing="0">
                    <tr>
                      <td width="700" align="right" valign="top" nowrap="nowrap"><script>
// (C) 2001 www.CodeLifter.com
// http://www.codelifter.com
// Free for all users, but leave in this header

//var theURL = '../logoff.asp';
//var width  = 300;
//var height = 100;

function popWindow(theURL, width, height) {
newWindow = window.open(theURL,'newWindow','toolbar=no,menubar=no,resizable=no,scrollbars=no,status=no,location=no,width='+width+',height='+height);
}
</script>
<style type="text/css">
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
	text-decoration:none;
}
</style>
<table width="600" height="25" align="right" cellpadding="0" cellspacing="0">
<tr width="" height="25">
<td width="" height="25" align="right" valign="top" nowrap="nowrap">

<span class="loggedin">lg@nicoco.eu&nbsp;|&nbsp;<a href="dashboard.asp?view=messages" class="loggedin"><font color="RED">1&nbsp;Unread Messages</font></a>&nbsp;|&nbsp;<a href="dashboard.asp" class="loggedin">My Dashboard</a>&nbsp;|&nbsp;<a href="_admin/admin.asp" class="loggedin">Admin</a>&nbsp;|&nbsp;<a href="http://www.villasdirect.com?testmode=no" class="loggedinred">TEST ON</a>&nbsp;|&nbsp;<a href="javascript:popWindow('../logoff.asp','300','100')" class="loggedin">Log Out</a></span>

</td>
</tr>
</table>
</td>
                    </tr>
                  </table></td>
                  <td width="20">&nbsp;</td>
                </tr>

<tr><td height="10" align="right"><table width="680" border="0" align="right" cellpadding="0" cellspacing="0"><tr><td align="right">
	
<ul class="drop" id="nav" name="nav">
  <li><a href="index.asp">HOME</a></li>
  <li><a href="index.asp">SEARCH</a></li>
  <li><a href="who-we-are.asp">ABOUT US</a></li>
  <li><a href="rentals_renters.asp">HOW TO RENT</a>
    <ul>
      <li class="dir"><a href="rentals_owners.asp">HOME OWNER</a></li>
      <li class="dir"><a href="rentals_renters.asp">HOLIDAY MAKER</a></li>
    </ul>
  </li>
  <li><a href="sell_your_property.asp">HOW TO SELL</a></li>
  <li><a href="sales_rental_agents.asp">AGENTS</a></li>
  <li><a href="support.asp">HELP</a></li>
</ul>

</td></tr></table></td></tr>
                
<!--                <tr>
                  <td><table width="680" border="0" align="right" cellpadding="0" cellspacing="0">
                    <tr>
                      <td width="81" align="right" nowrap="nowrap"><a href="index.asp" class="menu">HOME</a></td>
                      <td width="70" align="right"><a href="index.asp" class="menu">SEARCH</a></td>
                      <td width="83" align="right" nowrap="nowrap"><a href="who-we-are.asp" class="menu">ABOUT US</a></td>
                      <td width="112" align="right" nowrap="nowrap"><a href="rentals.asp" class="menu">HOW TO RENT</a></td>
                      <td width="114" align="right" nowrap="nowrap"><a href="sell_your_property.asp" class="menu">HOW TO SELL&nbsp;</a></td>
                      <td width="65" align="right" nowrap="nowrap" class="menu"><a href="sales_rental_agents.asp" class="menu">AGENTS</a></td>
                      <td width="70" align="right" nowrap="nowrap"><a href="javascript:popWindow('../logoff.asp','300','100')" class="menu">LOG OUT</a></td>
                      <td width="47" align="right" nowrap="nowrap"><a href="support.asp" class="menu">HELP</a></td>
                    </tr>
                  </table></td>
                  <td width="20">&nbsp;</td>
                </tr>-->
                
              </table><!--<table width="715" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="715" height="51" align="right" valign="bottom" class="menu">vv<table width="650" border="0" align="right" cellpadding="0" cellspacing="0">
              <tr>
                <td height="34"><table width="380" border="0" align="right" cellpadding="0" cellspacing="0">
                  <tr>
                      <td width="313" height="31" align="left" valign="top" class="loggedin" ></td>
                      <td width="53" align="right" valign="top" nowrap="nowrap"><!--include file="topmenu.asp"--><!--</td>
                      <td width="14" align="left" valign="top">&nbsp;</td>
                  </tr>
                </table></td>
              </tr>
              <tr>
                <td><table width="600" border="0" align="right" cellpadding="0" cellspacing="0">
                  <tr>
                    <td width="65" align="left"><a href="index2.asp" class="menu">HOME</a></td>
                    <td width="98" align="left"><a href="about-villas-direct.asp" class="menu">ABOUT US</a></td>
                    <td width="80" align="left"><a href="guides.asp" class="menu">GUIDES</a></td>
                    <td width="131" align="left"><a href="how-we-work.asp" class="menu">HOW WE WORK&nbsp;</a></td>
                    <td width="74" align="left"><a href="login.asp" class="menu">LOGIN</a></td>
                    <td width="152" align="left"><a href="customer-support.asp" class="menu">CUSTOMER SUPPORT</a></td>
                  </tr>
                </table></td>
              </tr>
            </table></td>
          </tr>
        </table>--></td>
      </tr>
    </table></td>
  </tr>
</table>
<table width="1002" border="0" align="center" cellpadding="0" cellspacing="0" background="images/topd_Spain_bkg.jpg" >
  <tr>
    <td width="1002" height="825" valign="top" >
    <table width="998" height="915" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td width="283" height="877" align="center" valign="top">
<link href="villasdirect.css" rel="stylesheet" type="text/css" />

<script Language="JavaScript">
<!-- 
function Blank_TextField_Validator()
{
// Check the value of the element named text_name from the form named text_form
if (form1.fb.value == "Location or Ref. No.")
{
  // If null display and alert box
   alert("Please either click a location on the map or type in the 'Country, Region, Town' text box.");
  // Place the cursor on the field for revision
   form1.fb.focus();
  // return false to stop further processing
   return (false);
}
// If text_name is not null continue processing
return (true);
}
-->
</script>

<table width="200" border="0" align="center" cellpadding="0" cellspacing="0"><form id="form1" name="form1" method="post" action="" onsubmit="return Blank_TextField_Validator()">
      <input name="autolng" id="autolng" type="hidden" />
      <input name="autolat" id="autolat" type="hidden" />
          <tr>
            <td width="200" height="47">&nbsp;</td>
          </tr>
          <tr>
            <td height="30" align="center" valign="top" class="para">
            <p class="pageheadlrg">
			
            <H1 class="pageheadlrg"><span class="specialtitles">PROPERTIES TO RENT IN</span><BR>SPAIN</H1>
			
            </p></td>
          </tr>
          <tr>
            <td height="18" align="center" valign="bottom" class="srprophead">HOLIDAY TYPES</td>
    </tr>
          <tr>
            <td height="28" align="left" valign="top" class="srsearchfields200"><label for="HolidayType"></label>
              <select name="HolidayType" class="srsearchfields200" id="HolidayType">
                <option>Beach, Coast</option>
                <option>Beach, Coast</option>
                <option>Beach, Coast</option>
                <option>Beach, Coast</option>
            </select></td>
          </tr>
          <tr>
            <td height="25" align="left" valign="bottom" class="specialtitles"><span class="srprophead">COUNTRY, REGION, TOWN</span></td>
          </tr>
          <tr>
            <td height="28" align="left" valign="top" class="specialtitles">
            <link rel="stylesheet" href="deps/jquery-ui.css" />  
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="http://code.jquery.com/ui/1.10.1/jquery-ui.js"></script>
<script>  
$(function() {
	function split( val ) {      
		return val.split( /,\s*/ );    
	}    
	function extractLast( term ) {      
		return split( term ).pop();    
	}     
	$( "#location" )      
		// don't navigate away from the field on tab when selecting an item      
		.bind( "keydown", function( event ) 
		{        
			if ( event.keyCode === $.ui.keyCode.TAB && $( this ).data( "ui-autocomplete" ).menu.active ) 
			{          
					event.preventDefault();        
			}
		})      
		.autocomplete({        
			source: function( request, response ) {
				$("#fb").val(request.term);
				$.ajax({
					url: "DDData.php",
					dataType: "json",
					data: { 
						term : request.term,
						country : $("#country").val(),
						region : $("#region").val(),
						beach : $("#beach").val(),
						ski : $("#ski").val(),
						golf : $("#golf").val(),
						luxury : $("#luxury").val(),
						exclusive : $("#exclusive").val(),
						rental : $("#rental").val(),
						sale : $("#sale").val()						
						},						
					type: "GET",
					success: function(data){
						response($.map(data, function(item){
							var itemText = "";
							if(item.country != "" && item.country != null) {
								itemText = item.country;
							}
							if(item.region != "" && item.region != null ) {
								if(itemText != "") itemText = itemText + ", " 
								itemText = itemText + item.region
							}
							if(	item.location != "" && item.location != null) {
								if(itemText != "") itemText = itemText + ", " 
								itemText = itemText + item.location
							}					
							return {
								value: item.ID,
								label: itemText
							}
						}))
					}           
        	});        
		},        
		search: function() {          
		  // custom minLength          
		  var term = extractLast( this.value );          
		  if ( term.length < 1 ) {            
		  	return false;          
			}        
		},        
		focus: function() {          
		  	// prevent value inserted on focus          
		  	return false;        },        
		select: function( event, ui ) {          
		  	var terms = split( this.value );         
		  	// remove the current input          
		  	terms.pop();          
		  	// add the selected item          
		  	terms.push( ui.item.label );          
		  	// add placeholder to get the comma-and-space at the end          
		  	//terms.push( "" );          
		  	this.value = ui.item.label;    
		  	
		  	$("#fb").val(ui.item.value);
		  	      
			return false;        
		}      
	});  
});  
</script>

	<input name="searchtermtext" class="srsearchfieldsnw" id="location" onfocus="if (this.value=='Location or Ref. No.') this.value = ''"
	onblur="if (this.value=='') this.value = 'Location or Ref. No.'"  value="Location or Ref. No." style="width: 195px;">
	<input id="fb" name="fb" value="-1" style="left:" type="hidden" />
    <input id="country" name="country" value="Spain" type="hidden" />
    <input id="region" name="region" value="" type="hidden" />
    <input id="beach" name="beach" value="" type="hidden" />
    <input id="ski" name="ski" value="" type="hidden" />
    <input id="golf" name="golf" value="" type="hidden" />
    <input id="luxury" name="luxury" value="" type="hidden" />
    <input id="exclusive" name="exclusive" value="" type="hidden" />
    <input id="rental" name="rental" value="" type="hidden" />
	<input id="sale" name="sale" value="" type="hidden" />    
    </td>
          </tr>     
    <tr>
    <td height="25" align="left" valign="bottom" class="srsearchfieldslrg"><span class="srprophead">SEARCH RANGE</span>   </td></tr>     
          <tr>
            <td height="25" align="left" valign="top"><table width="200" border="0" align="left" cellpadding="0" cellspacing="0">
              <tr>
                <td width="117" height="22" align="left" valign="middle">
                    <select name="distance" id="distance" class="srsearchfields80" >
	<option value="1">< 1</option>
    <option value="5" selected>5</option>                    
    <option value="10">10</option>
    <option value="25">25</option>
    <option value="50">50</option>
    <option value="75">75</option>
    <option value="100">100</option>
    <option value="250">250</option>
    
    <option value="500">500</option>
    <option value="750">750</option>
    <option value="5000">5000</option> 
          
  </select></td>
                <td width="83" align="left" valign="middle" class="srsearchfields60">
                    <select name="mkm" id="mkm" class="srsearchfields80">
    <option value="Miles" selected>Miles</option>
    <option value="Kms">Kms</option>
  </select></td>
              </tr>
            </table></td>
  </tr>
    <tr>
            <td height="30" align="center" valign="top" class="srsearchfieldslrg">                
<table width="200" border="0" align="left" cellpadding="0" cellspacing="0">

   
              <tr>
                <td colspan="2" align="left" class="parabold">
                <table width="200" cellpadding="0" cellspacing="0">
                 <tr>
                 <td width="116" height="25" align="left" valign="bottom"><span class="srprophead">ARRIVING</span></TD>
                 <td width="82" valign="bottom"><span class="srprophead">FLEXIBLE</span></td>
                 </tr>
                 <tr>
                 <td width="116" align="left" valign="middle" nowrap="nowrap"><input name="f_date1" class="srsearchfields80" id="f_date1" value="29-Mar-2013" size="11" maxlength="11" OnClick="document.getElementById('nodate').checked = ''"/>&nbsp;<button id="f_btn1" class="calendar" OnClick="document.getElementById('nodate').checked = ''"> &nbsp;&nbsp;</button>                   <script type="text/javascript">//<![CDATA[
			      Calendar.setup({
				  inputField : "f_date1",
		          trigger    : "f_btn1",
//		          onSelect   : function() { this.hide(); document.forms['form1'].submit() },
		          onSelect   : function() { this.hide()},				  		          //showTime   : 12,
				  min: 20130329,
				  max: 20140706,
				  fdow: 6,
		          dateFormat : "%d-%b-%Y"
			      });
				  //]]></script></TD>
                 <td width="82" align="left" valign="middle"><select name="plusminus" size="1" id="plusminus" class="srsearchfields80">
                    <option value="0">0 Days</option>
                    <option value="7" selected="selected">+/-7 Days</option>
                    <option value="14">+/-14 Days</option>
                    <option value="21">+/-21 Days</option>
                    <option value="28">+/-28 Days</option>
                  </select></td>
                 </tr>                 
                 </table>
                </td>
              </tr>
	
                <tr>
                  <td height="25" colspan="2" align="left" valign="bottom" class="parabold"><!--<a href="search-results.asp?lng=&lat=&location=&ResetDate=1" title="Reset Date"><img src="images/check_box.jpg" width="16" height="16" border="0" /></a><span class="parablue11">&nbsp;I do not know my travel dates</span>--><input id="nodate" name="nodate" type="checkbox" value="" onClick="document.getElementById('f_date1').value = ''"/>
                  I do not know my travel dates</td>
                </tr>
	                
                <tr>
                  <td width="116" height="25" valign="bottom" class="srprophead">DURATION</td>
                  <td width="84" valign="bottom" class="srprophead">SLEEPS</td>
                </tr>
                <tr>
                  <td align="left" valign="middle" class="srsearchfields80"><select name="staydays" size="1" id="staydays" class="srsearchfields80" onchange="javascript: document.forms['form1'].submit()">
                    <option  value="7" selected="selected">1 week</option>
                    <option value="14" >2 weeks</option>
                    <option value="21" >3 weeks</option>
                    <option value="28" >4 weeks</option>
                    <option value="35" >5 weeks</option>
                    <option value="42" >6 weeks</option>
                    <option value="49" >7 weeks</option>
                    <option value="56" >8 weeks</option>
                    <!--<option value="mid" >Mid-Term Rentals</option>
                    <option value="long" >Long Term Rentals</option>-->
                  </select>
 
</td>
                  <td align="left" valign="middle" class="parabold"><!--<select name="listbox" size="1"  id="listbox" class="srsearchfields80">
                    <option selected="selected">Any</option>
                  </select>-->
                    <span class="srsearchfields80">
                    <select name="people2" id="people2" class="srsearchfields80">
                      <option class="srsearchfields80" value="Any" selected>Any</option>
                      <option class="srsearchfields80" value="2">2-4</option>
                      <option class="srsearchfields80" value="4">4-6</option>
                      <option class="srsearchfields80" value="6">6-8</option>
                      <option class="srsearchfields80" value="8">8-10</option>
                      <option class="srsearchfields80" value="10+">10+</option>
                    </select>
                  </span></td>
              </tr>
              </table>
</td>
          </tr>
          <tr>
            <td height="14" align="center" valign="bottom" >&nbsp;</td>
          </tr>

          <!--<tr>
            <td height="11" align="center" valign="bottom" ><img src="images/pixelgreen.gif" alt="" width="180" height="2" /></td>
          </tr>-->
          <!--<tr>
            <td><table width="180" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <td width="90" height="20" align="center" valign="bottom" class="parabold">&nbsp;Min Price</td>
                <td width="90" height="20" align="center" valign="bottom" class="parabold">&nbsp;Max Price</td>
              </tr>
              <tr>
                <td width="90" height="30" align="center" valign="top">
                  <select name="listbox3" size="1" class="srsearchfields" id="listbox2">
                    <option selected="selected">Any</option>
                    <option>00 000</option>
                  </select></td>
                <td width="90" align="center" valign="top">
                  <select name="listbox5" size="1" class="srsearchfields" id="listbox4">
                    <option>Any</option>
                    <option>00 000</option>
                  </select>
                </td>
              </tr>
            </table></td>
          </tr>
          <tr>
            <td height="35" valign="top" class="para"><table width="180" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <td width="90" height="27" align="center"><span class="parabold">Currency</span></td>
                <td width="90" align="center"><select name="listbox6" id="listbox6" class="srsearchfields">
                  <option>EUR</option>
                  <option>GBP</option>
                  <option>USD</option>
                </select></td>
              </tr>
            </table></td>
          </tr>-->
          <tr>
            <td height="73" align="center" valign="top"><input type="image" src="images/search_now.jpg" alt="search for a property now" id="submit" width="201" height="56" onClick="document.getElementById('form-id').submit();"></td>
  </tr>
          <tr>
            <td height="262" valign="top"><table width="156" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <td colspan="2" align="left"><span class="srprophead">REQUIREMENTS</span></td>
              </tr>
              <tr>
                  <td><input type="checkbox" name="pool" id="pool" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe">
                    <label for="checkbox3" class="paraleft"><span class="parablue13">Swimming Pool</span></label>
                  </span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="aircon" id="aircon" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="parablue13">
                    <label for="checkbox2"><span class="parablue13">Air Conditioned</span></label>
                  </span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="sattv" id="sattv" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe">
                    <label for="checkbox2" class="paraleft"><span class="parablue13">Satellite TV</span></label>
                  </span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="internet" id="internet" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe">
                    <label for="checkbox3" class="paraleft"><span class="parablue13">Internet Access</span></label>
                  </span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="restaurants" id="restaurants" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe">
                    <label for="checkbox6" class="paraleft"><span class="parablue13">Restaurants Nearby</span></label>
                  </span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="shops" id="shops" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe"><span class="parablue13">Shops Nearby</span></span></td>
                </tr>
                <tr>
                <td width="26"><input type="checkbox" name="child_friendly" id="child_friendly" / class="textboxframe"  ""/></td>
                  <td width="130" align="left"><span class="texboxframe"><span class="parablue13">Child Friendly</span></span></td>
              </tr>
                <tr>
                  <td><input type="checkbox" name="disabled_access" id="disabled_access" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe"><span class="parablue13">Disabled Access</span></span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="pet_friendly" id="pet_friendly" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="textboxframe"><span class="parablue13">Pet Friendly</span></span></td>
                </tr>
                <tr>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
              </table>
              <table width="156" border="0" align="center" cellpadding="0" cellspacing="0">
                <tr>
                  <td colspan="2" align="left"><span class="srprophead">NEAR TO</span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="beach" id="beach" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="paraleft"><span class="parablue13">Beach</span></span></td>
                </tr>
                <tr>
                  <td width="26"><input type="checkbox" name="golf" id="golf" / class="textboxframe"  ""/></td>
                  <td width="154" align="left"><span class="paraleft"><span class="parablue13">Golf</span></span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="skiing" id="skiing" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="paraleft"><span class="parablue13">Skiing</span></span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="tennis" id="tennis" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="paraleft"><span class="parablue13">Tennis</span></span></td>
                </tr>
                <tr>
                  <td><input type="checkbox" name="hiking" id="hiking" / class="textboxframe"  ""/></td>
                  <td align="left"><span class="paraleft"><span class="parablue13">Hiking</span></span></td>
                </tr>
                <tr>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
              </table>

              <table width="156" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <td colspan="2" align="left"><span class="srprophead">PAYMENT OPTIONS</span></td>
              </tr>
              <tr>
                  <td width="26" valign="middle"><input type="checkbox" name="ccpayments" id="ccpayments" / class="textboxframe"  ""/></td>
                  <td width="130" height="18" align="left" valign="middle" class="parablue13">Pay By Card&nbsp; <a href="" title="Check this box if you want to see only properties which accept payment by credit card/PayPal"><img src="images/infoonblue.gif" width="15" height="15" border="0"/></a></td>
              </tr>
              <tr>
                  <td width="26"><input type="checkbox" name="paymonthly" id="paymonthly" / class="textboxframe"  ""/></td>
                  <td width="130" height="18" align="left" valign="middle" class="parablue13">Pay Monthly&nbsp; <a href="" title="Check this box if you'd like to see properties whose owners accept monthly payments"><img src="images/infoonblue.gif" alt="" width="15" height="15" border="0" /></a></td>
              </tr>
                <tr>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>              
            </table>
              
              </td>
          </tr>
          <tr>
            <td height="58" align="center" valign="top"><input type="image" src="images/search_now.jpg" alt="search for a property now" width="201" height="56" onClick="document.getElementById('form-id').submit();"></td>
    </tr>
          <tr>
            <td height="68" align="left" valign="top" class="parablue11"><p><br />
            List of All Properties in FRANCE:</p></td>
          </tr>
          <tr>
            <td height="91" align="center" valign="top" class="parablue11"><a href="http://www.villasdirect.com/rentals_owners.asp"><img src="images/bt_have_property_to_rent.jpg" width="199" height="71" alt="Rent a holiday Property" border="0" onmouseover="this.style.cursor='pointer'"/></a></td>
    </tr>
</form>
        </table>
<!--include file="search-panel.asp"-->
        <td width="715" align="left" valign="top">
        <table width="689" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="689" height="21">&nbsp;</td>
          </tr>
          <tr>
            <td height="315" valign="top" class="td_imagetext">
            <!--<table width="689" height="347">
            <tr><td colspan="3" height="20">&nbsp;</td></tr>
            <tr><td width="37">&nbsp;</td>
            <td width="616" align="right" valign="top"></TD>
            <td width="20">&nbsp;</td></tr>
            </table>-->
            </td>
          </tr>
          <tr>
            <td height="413" valign="top" align="center" bgcolor="#FFFFFF"><BR>


<script src="http://maps.google.com/maps/api/js?sensor=false" type="text/javascript"></script> 
    <div id="map" style="width: 665px; height: 600px"></div>
  
    <form onsubmit="showAddress(); return false" id="form2" name="form2" action="top_destinations.asp?Country=Italy">
      <input id="search" type="hidden" value="SPAIN" />
    </form>
        
    <div id="message"></div>

    <noscript><b>JavaScript must be enabled in order for you to use Google Maps.</b> 
      However, it seems JavaScript is either disabled or not supported by your browser. 
      To view Google Maps, enable JavaScript by changing your browser options, and then 
      try again.
    </noscript>

    <script type="text/javascript">
    
	var myOptions = {
		zoom: 8,
		scrollwheel: false,
	  	mapTypeId: google.maps.MapTypeId.ROADMAP
	  };
      var map = new google.maps.Map(document.getElementById("map"), myOptions);

      // ====== Create a Client Geocoder ======
      var geo = new google.maps.Geocoder(); 
	  geo.geocode({'address': document.getElementById("search").value}, function (results, status) {
         var ne = results[0].geometry.viewport.getNorthEast();
         var sw = results[0].geometry.viewport.getSouthWest();
		 ParseLocation(results[0].geometry.location);
		 
		 map.fitBounds(results[0].geometry.viewport); 
		 placeMarkers();   
	
		var listener = google.maps.event.addListener(map, "idle", function() { 
		var mapautozoom = map.getZoom() + 1;
//		If (document.getElementById("search").value!='US'){
		  map.setZoom(mapautozoom); 
		  google.maps.event.removeListener(listener);	

	      }); 
	  });     
	  
	 function ParseLocation(location) {
      var autolat = location.lat().toString().substr(0, 12);
      var autolng = location.lng().toString().substr(0, 12);
	  document.getElementById("autolng").value = autolng;
	  document.getElementById("autolat").value = autolat;
	 } 
	 
	var xmlsource = '<markers><marker town="" region="Almeria" country="Spain" lat="37.145" lng="-1.8842" URL="" title = "Spain, Almeria" type="green"/><marker town="" region="Almunecar" country="Spain" lat="36.7422" lng="-3.6955" URL="" title = "Spain, Almunecar" type="green"/><marker town="" region="Alpujarras" country="Spain" lat="36.919" lng="-3.4856" URL="" title = "Spain, Alpujarras" type="green"/><marker town="" region="Andalucia" country="Spain" lat="37.722475" lng="-3.14355" URL="" title = "Spain, Andalucia" type="green"/><marker town="" region="Andalucia Inland" country="Spain" lat="37.8070180" lng="-5.1018039" URL="" title = "Spain, Andalucia Inland" type="green"/><marker town="" region="Aragon/Navarre/La Rioja" country="Spain" lat="42.2870733" lng="-2.5396030" URL="" title = "Spain, Aragon/navarre/la Rioja" type="green"/><marker town="" region="Asturias" country="Spain" lat="43.4274" lng="-5.7423" URL="" title = "Spain, Asturias" type="green"/><marker town="" region="Barcelona Coast" country="Spain" lat="41.4177165" lng="1.9326228" URL="" title = "Spain, Barcelona Coast" type="green"/><marker town="" region="Canary Islands" country="Spain" lat="27.9235191" lng="-15.5745507" URL="" title = "Spain, Canary Islands" type="green"/><marker town="" region="Castile-La Mancha" country="Spain" lat="39.1750302" lng="-1.5214676" URL="" title = "Spain, Castile-La Mancha" type="green"/><marker town="" region="Castile-León" country="Spain" lat="40.1559244" lng="-5.2436354" URL="" title = "Spain, Castile-León" type="green"/><marker town="" region="Catalonia Inland/Pyrenees" country="Spain" lat="41.8110900" lng="2.0947760" URL="" title = "Spain, Catalonia Inland/pyrenees" type="green"/><marker town="" region="Costa Almeria/Tropical" country="Spain" lat="37.9180827" lng="-6.5446482" URL="" title = "Spain, Costa Almeria/tropical" type="green"/><marker town="" region="Costa Blanca" country="Spain" lat="38.4848285" lng="-0.3719071" URL="" title = "Spain, Costa Blanca" type="green"/><marker town="" region="Costa Brava" country="Spain" lat="41.7723" lng="2.9993" URL="" title = "Spain, Costa Brava" type="green"/><marker town="" region="Costa Calida" country="Spain" lat="37.58585" lng="-1.278" URL="" title = "Spain, Costa Calida" type="green"/><marker town="" region="Costa de la Luz" country="Spain" lat="36.3190547" lng="-6.1500474" URL="" title = "Spain, Costa De La Luz" type="green"/><marker town="" region="Costa de Valencia" country="Spain" lat="39.5657820" lng="-0.5305090" URL="" title = "Spain, Costa De Valencia" type="green"/><marker town="" region="Costa del Azahar" country="Spain" lat="40.4654987" lng="0.1787657" URL="" title = "Spain, Costa Del Azahar" type="green"/><marker town="" region="Costa del Sol" country="Spain" lat="36.5139916" lng="-1.2988666" URL="" title = "Spain, Costa Del Sol" type="green"/><marker town="" region="Costa Dorada" country="Spain" lat="41.2609028" lng="1.4380056" URL="" title = "Spain, Costa Dorada" type="green"/><marker town="" region="Extremadura" country="Spain" lat="40.2034593" lng="-5.9614499" URL="" title = "Spain, Extremadura" type="green"/><marker town="" region="Finestrat" country="Spain" lat="38.5353" lng="-0.1332" URL="" title = "Spain, Finestrat" type="green"/><marker town="" region="Granada" country="Spain" lat="36.9052" lng="-3.5154" URL="" title = "Spain, Granada" type="green"/><marker town="" region="Green Spain" country="Spain" lat="41.9011352" lng="-8.0833511" URL="" title = "Spain, Green Spain" type="green"/><marker town="" region="Madrid" country="Spain" lat="42.7705252" lng="-3.5404748" URL="" title = "Spain, Madrid" type="green"/><marker town="" region="Marbella" country="Spain" lat="36.39945" lng="-4.77465" URL="" title = "Spain, Marbella" type="green"/><marker town="" region="Minorca" country="Spain" lat="39.8472590" lng="4.2558490" URL="" title = "Spain, Minorca" type="green"/><marker town="" region="Murcia" country="Spain" lat="37.9923310" lng="-1.1304575" URL="" title = "Spain, Murcia" type="green"/><marker town="" region="San Roque, Cadiz" country="Spain" lat="36.5110091" lng="-4.8754263" URL="" title = "Spain, San Roque, Cadiz" type="green"/><marker town="" region="Valencia Region Inland" country="Spain" lat="38.3671462" lng="-0.8973142" URL="" title = "Spain, Valencia Region Inland" type="green"/><marker town="" region="Western Alpujarras" country="Spain" lat="36.91900" lng="-3.48564" URL="" title = "Spain, Western Alpujarras" type="green"/></markers>'     

	  var infoWindow = new google.maps.InfoWindow;
	  $( $.parseXML( xmlsource ) ).find("marker").each(function() {
	  	var lng = $(this).attr('lng');
	  	var lat = $(this).attr('lat');
	  	marker = new google.maps.Marker({
      		map:map,
      		draggable:true,
      		animation: google.maps.Animation.DROP,
      		position: new google.maps.LatLng(59.32522, 18.07002)
      	});
	  });
      google.maps.event.addListener(marker, 'click');
	 	  
	  function placeMarkers(){
	  	var xmlList = $.parseXML(xmlsource);
		var markers = $(xmlList).find('marker');
		for (var i = 0; i < markers.length; i++) {
        var latlng = new google.maps.LatLng(parseFloat($(markers[i]).attr("lat")),
                                    parseFloat($(markers[i]).attr("lng")));
		var type = $(markers[i]).attr("type");
		var url = $(markers[i]).attr("url");
		var title = $(markers[i]).attr("title");
		var region = $(markers[i]).attr("region");
		var town = $(markers[i]).attr("town");
		var country = $(markers[i]).attr("country");
		var imgnam = "";
		if(type == "green")	{
			imgnam = "http://www.villasdirect.com/images/red_dot.png";
		}else{
			imgnam = "http://www.villasdirect.com/images/red_dot.png";
		}		
		var img = new google.maps.MarkerImage(
			imgnam,
			new google.maps.Size(30,35),
			new google.maps.Point(0,0),
			new google.maps.Point(15,35)
		);
		//add a link to your xml that can be inserted here where I have http://www.google.com
		var html = "<div class = 'MarkerPopUp' style='width: 150px; height: 25px;'><a href='" + $(markers[i]).attr('url') + "' Title=' + $(markers[i]).attr('Title') + '>" + $(markers[i]).attr('region') + ', ' + $(markers[i]).attr('town') + "</a></div>";									
        var marker = new google.maps.Marker({position: latlng, map:map, icon:img, html:html, url:url, title:title});
		
//		var infowindow1 = new google.maps.InfoWindow();
//		google.maps.event.addListener(marker, 'mouseover', function() {
//			infowindow1.setContent(this.html);
//	        infowindow1.open(map, this);

//	    });
		
	    google.maps.event.addListener(marker, 'click', function() {
            document.getElementById("town").value = this.town;
			document.getElementById("region").value = this.region;
            document.getElementById("country").value = this.country;
            document.getElementById("location").value = this.title;
            document.getElementById("fb").value = this.title;
			document.getElementById("form1").submit();
//	    window.location.href = marker.url;
		
	    });

		}
		  
	  }

    </script><BR>&nbsp;</td>
          </tr>
        </table>
        </td>
      </tr>
      </table>
</td>
  </tr>
  <tr>
    <td height="75" valign="top" background="images/topd_bkg_bttm.jpg" >&nbsp;</td>
  </tr>
</table>
<table width="968" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="90%" valign="top"><div align="center" class="copyright">
    
    </div></td>
  </tr> 
</table>
</body>
</html>

<!--<span class="copyright"><br />
Use of this website constitutes acceptance of the TERMS OF USE, BOOKING TERMS and PRIVACY POLICY <br />
</span>-->
<span class="copyright">&copy; Copyright VillasDirect Limited 1997 - 2013 All Rights Reserved&nbsp;-&nbsp;Registered in the UK: 07929131&nbsp;|&nbsp;<a href="privacy.asp">Your Privacy</a></span>

Thanks in advance!
ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 1 Answer and 9 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros