﻿function WAMapRef(mapObj)  {
  this.obj = mapObj;
  this.directions = false;
  this.icons = [];
  this.markers = [];
  this.addresses = [];
  this.points = [];
  this.getPointByAddress = getPointByAddressFunc;
  this.addressFailed = true;
  return this;
}

function WAMapPoint(theMarker, theAddress, theIcon)  {
  this.icon = theIcon;
  this.marker = theMarker;
  this.address = theAddress;
  return this;
}

function getPointByAddressFunc(value,attname)  {
  if (!attname) attname = "street";
  for (var x=0; x < this.addresses.length; x++) {
    if (eval("this.addresses[x]."+attname) == value)  {
      return WAMapPoint(this.markers[x],this.addresses[x],this.icons[x]);
    }
  }
  return false;
}

function getHTTPObject(){   
  if (window.ActiveXObject)        
    return new ActiveXObject("Microsoft.XMLHTTP");   
  else if (window.XMLHttpRequest)        
    return new XMLHttpRequest();   
  else {
    return null;
  }
}

function searchCache(searchStr, zip) {
	var xmlDoc = null;
  if (window.ActiveXObject) {//IE
    xmlDoc=new ActiveXObject("Microsoft.XMLDOM");
  } else if(navigator.userAgent && navigator.userAgent.toLowerCase().indexOf('webkit') >= 0) { //webkit (Safari, Chrome)
  	var coordinates = '';
    xmlDoc = getHTTPObject();
    if(xmlDoc) {
      xmlDoc.onreadystatechange = function() {
        if(xmlDoc.readyState == 4) {
          var x = xmlDoc.responseXML.getElementsByTagName("geocode_entry");
          var geocode, id;
          searchStr = searchStr.replace(/,/g, ''); //remove commas
          for (i=0; i < x.length; i++) {
            id = x[i].getAttribute("ID");
            if (id == searchStr) {
              coordinates = x[i].getElementsByTagName("geocode")[0].childNodes[0].nodeValue;
              return coordinates;
            }
          }
        }
      };
      xmlDoc.open("GET", "_promaps_cache/_promaps_geocache.xml", false);
      xmlDoc.send(null);
    }
    
    return coordinates;
  } else if (document.implementation.createDocument) {//gecko (Mozilla, Firefox, Opera)
    xmlDoc=document.implementation.createDocument("","",null);
  } else {
    return '';
  }
  if (xmlDoc != null) {
    xmlDoc.async=false;
    if(xmlDoc.load("_promaps_cache/_promaps_geocache.xml")) {
      var x=xmlDoc.getElementsByTagName("geocode_entry");
      var geocode, id;
      searchStr = searchStr.replace(/,/g, ''); //remove commas
      for (i=0; i < x.length; i++) {
        id = x[i].getAttribute("ID");
        if (id == searchStr) {
          return x[i].getElementsByTagName("geocode")[0].childNodes[0].nodeValue;
        }
      }
    }
  }
  
  return '';
}

function addToCache(fullAddress,zip, geocode){
  httpObject = getHTTPObject();
  if (httpObject != null) {
    httpObject.open("POST", "google_javascript/promaps_geocache_.js", true);
    httpObject.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
    var entryId = fullAddress.replace(/,/g, '');
    if (zip != '') {
      fullAddress = fullAddress.replace(zip+',', '');
    }
    entryId = escape(entryId);
    fullAddress = escape(fullAddress);
    geocode = escape(geocode);
    httpObject.send("sender=promapsforgoogle&action=add&entryId="+entryId+"&address="
+fullAddress+"&geocode="+geocode);
  }
}


function wagmp_map_1() {
  if(GBrowserIsCompatible()) {
    if(!document.getElementById('wagmp_map_1')) return false;
    var map = new GMap2(document.getElementById('wagmp_map_1'));
    wagmp_map_1_obj = new WAMapRef(map);
    map.enableContinuousZoom();
    map.enableDoubleClickZoom();
    map.addControl(new GLargeMapControl());
    map.addControl(new GScaleControl());
    map.addControl(new GMapTypeControl());
    map.addControl(new GOverviewMapControl());
    var geocoder = new GClientGeocoder();
    
    var fromAddress = {
      enabled: false,
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      full: ''
    };

    var icon_0 = new GIcon();
    icon_0.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_0.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_0.iconSize = new GSize(34,35);
    icon_0.shadowSize = new GSize(34,35);
    icon_0.iconAnchor = new GPoint(9,33);
    icon_0.infoWindowAnchor = new GPoint(19,0);
    icon_0.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_0.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_0.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_0.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_0 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Castelo_de_Sao_Jorge" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Castelo de S. Jorge</span></a><br />      <br />      <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Castle of São Jorge (Castle of Saint George) occupies a commanding position overlooking the city of Lisbon, the capital of Portugal, and the broad Tagus River beyond. </span></td><br />    <td width="133" align="center" valign="top"><img src="/images/castelo.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.713828,-9.132986',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.713828',
      longitude: '-9.132986',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_0.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_0.full, address_0.zip);
    }
    if (cacheReturn != "" || (address_0.addressType == "coordinates")) {
      if(address_0.addressType == "coordinates") {
        var latitude = address_0.latitude;
        var longitude = address_0.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_0 = new GMarker(point, icon_0);
        GEvent.addListener(marker_0, 'click', function() {
          marker_0.openInfoWindowHtml(address_0.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_0' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_0);
        }
          wagmp_map_1_obj.markers.push(marker_0);
          wagmp_map_1_obj.addresses.push(address_0);
          wagmp_map_1_obj.icons.push(icon_0);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_0.addressType == "address") {
      geocoder.getLatLng (
      address_0.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_0.full, '', point);
          var marker_0 = new GMarker(point, icon_0);
          GEvent.addListener(marker_0, 'click', function() {
            marker_0.openInfoWindowHtml(address_0.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_0' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_0);
          }
        } else {
          var noZipAddress = address_0.full.replace((address_0.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_0.full, address_0.zip, point);
                var marker_0 = new GMarker(point, icon_0);
                GEvent.addListener(marker_0, 'click', function() {
                  marker_0.openInfoWindowHtml(address_0.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_0' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_0);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_1 = new GIcon();
    icon_1.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_1.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_1.iconSize = new GSize(34,35);
    icon_1.shadowSize = new GSize(34,35);
    icon_1.iconAnchor = new GPoint(9,33);
    icon_1.infoWindowAnchor = new GPoint(19,0);
    icon_1.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_1.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_1.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_1.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_1 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Alfama" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Alfama</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Alfama (Portuguese pronunciation is the oldest district of Lisbon, spreading on the slope between the Castle of Lisbon and the Tejo river.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/alfama.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.711266,-9.127729',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.711266',
      longitude: '-9.127729',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_1.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_1.full, address_1.zip);
    }
    if (cacheReturn != "" || (address_1.addressType == "coordinates")) {
      if(address_1.addressType == "coordinates") {
        var latitude = address_1.latitude;
        var longitude = address_1.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_1 = new GMarker(point, icon_1);
        GEvent.addListener(marker_1, 'click', function() {
          marker_1.openInfoWindowHtml(address_1.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_1' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_1);
        }
          wagmp_map_1_obj.markers.push(marker_1);
          wagmp_map_1_obj.addresses.push(address_1);
          wagmp_map_1_obj.icons.push(icon_1);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_1.addressType == "address") {
      geocoder.getLatLng (
      address_1.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_1.full, '', point);
          var marker_1 = new GMarker(point, icon_1);
          GEvent.addListener(marker_1, 'click', function() {
            marker_1.openInfoWindowHtml(address_1.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_1' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_1);
          }
        } else {
          var noZipAddress = address_1.full.replace((address_1.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_1.full, address_1.zip, point);
                var marker_1 = new GMarker(point, icon_1);
                GEvent.addListener(marker_1, 'click', function() {
                  marker_1.openInfoWindowHtml(address_1.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_1' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_1);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_2 = new GIcon();
    icon_2.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_2.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_2.iconSize = new GSize(34,35);
    icon_2.shadowSize = new GSize(34,35);
    icon_2.iconAnchor = new GPoint(9,33);
    icon_2.infoWindowAnchor = new GPoint(19,0);
    icon_2.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_2.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_2.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_2.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_2 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Bairro_Alto" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Bairro Alto</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Bairro Alto is one of the oldest districts in Lisbon. Dozens of fado singing clubs animate the area.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/bairroalto.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.712606,-9.14762',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.712606',
      longitude: '-9.14762',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_2.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_2.full, address_2.zip);
    }
    if (cacheReturn != "" || (address_2.addressType == "coordinates")) {
      if(address_2.addressType == "coordinates") {
        var latitude = address_2.latitude;
        var longitude = address_2.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_2 = new GMarker(point, icon_2);
        GEvent.addListener(marker_2, 'click', function() {
          marker_2.openInfoWindowHtml(address_2.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_2' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_2);
        }
          wagmp_map_1_obj.markers.push(marker_2);
          wagmp_map_1_obj.addresses.push(address_2);
          wagmp_map_1_obj.icons.push(icon_2);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_2.addressType == "address") {
      geocoder.getLatLng (
      address_2.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_2.full, '', point);
          var marker_2 = new GMarker(point, icon_2);
          GEvent.addListener(marker_2, 'click', function() {
            marker_2.openInfoWindowHtml(address_2.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_2' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_2);
          }
        } else {
          var noZipAddress = address_2.full.replace((address_2.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_2.full, address_2.zip, point);
                var marker_2 = new GMarker(point, icon_2);
                GEvent.addListener(marker_2, 'click', function() {
                  marker_2.openInfoWindowHtml(address_2.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_2' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_2);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_3 = new GIcon();
    icon_3.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_3.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_3.iconSize = new GSize(34,35);
    icon_3.shadowSize = new GSize(34,35);
    icon_3.iconAnchor = new GPoint(9,33);
    icon_3.infoWindowAnchor = new GPoint(19,0);
    icon_3.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_3.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_3.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_3.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_3 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Santa_Justa_Lift" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Elevador de Santa Justa</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Santa Justa Lift was designed by Raul Mesnier de Ponsard, an engineer born in Oporto to French parents, and apprentice of Gustave Eiffel.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/santajusta.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.712112,-9.139391',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.712112',
      longitude: '-9.139391',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_3.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_3.full, address_3.zip);
    }
    if (cacheReturn != "" || (address_3.addressType == "coordinates")) {
      if(address_3.addressType == "coordinates") {
        var latitude = address_3.latitude;
        var longitude = address_3.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_3 = new GMarker(point, icon_3);
        GEvent.addListener(marker_3, 'click', function() {
          marker_3.openInfoWindowHtml(address_3.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_3' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_3);
        }
          wagmp_map_1_obj.markers.push(marker_3);
          wagmp_map_1_obj.addresses.push(address_3);
          wagmp_map_1_obj.icons.push(icon_3);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_3.addressType == "address") {
      geocoder.getLatLng (
      address_3.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_3.full, '', point);
          var marker_3 = new GMarker(point, icon_3);
          GEvent.addListener(marker_3, 'click', function() {
            marker_3.openInfoWindowHtml(address_3.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_3' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_3);
          }
        } else {
          var noZipAddress = address_3.full.replace((address_3.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_3.full, address_3.zip, point);
                var marker_3 = new GMarker(point, icon_3);
                GEvent.addListener(marker_3, 'click', function() {
                  marker_3.openInfoWindowHtml(address_3.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_3' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_3);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_4 = new GIcon();
    icon_4.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_4.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_4.iconSize = new GSize(34,35);
    icon_4.shadowSize = new GSize(34,35);
    icon_4.iconAnchor = new GPoint(9,33);
    icon_4.infoWindowAnchor = new GPoint(19,0);
    icon_4.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_4.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_4.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_4.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_4 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/S%C3%A9_de_Lisboa" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Sé de Lisboa</span></a><br />      <br />      <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Santa Maria Maior de Lisboa or Sé de Lisboa is the cathedral of Lisbon and the oldest church in the city.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/se.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.712974,-9.133029',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.712974',
      longitude: '-9.133029',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_4.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_4.full, address_4.zip);
    }
    if (cacheReturn != "" || (address_4.addressType == "coordinates")) {
      if(address_4.addressType == "coordinates") {
        var latitude = address_4.latitude;
        var longitude = address_4.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_4 = new GMarker(point, icon_4);
        GEvent.addListener(marker_4, 'click', function() {
          marker_4.openInfoWindowHtml(address_4.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_4' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_4);
        }
          wagmp_map_1_obj.markers.push(marker_4);
          wagmp_map_1_obj.addresses.push(address_4);
          wagmp_map_1_obj.icons.push(icon_4);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_4.addressType == "address") {
      geocoder.getLatLng (
      address_4.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_4.full, '', point);
          var marker_4 = new GMarker(point, icon_4);
          GEvent.addListener(marker_4, 'click', function() {
            marker_4.openInfoWindowHtml(address_4.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_4' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_4);
          }
        } else {
          var noZipAddress = address_4.full.replace((address_4.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_4.full, address_4.zip, point);
                var marker_4 = new GMarker(point, icon_4);
                GEvent.addListener(marker_4, 'click', function() {
                  marker_4.openInfoWindowHtml(address_4.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_4' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_4);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_5 = new GIcon();
    icon_5.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_5.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_5.iconSize = new GSize(34,35);
    icon_5.shadowSize = new GSize(34,35);
    icon_5.iconAnchor = new GPoint(9,33);
    icon_5.infoWindowAnchor = new GPoint(19,0);
    icon_5.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_5.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_5.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_5.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_5 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Rossio_Square" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Praça do Rossio</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Rossio is the popular name of the Pedro IV Square (Portuguese: Praça de D. Pedro IV) in the city of Lisbon, in Portugal. It is located in the Pombaline Downtown of Lisbon and has been one of its main squares since the Middle Ages.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/rossio.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.713736,-9.139316',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.713736',
      longitude: '-9.139316',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_5.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_5.full, address_5.zip);
    }
    if (cacheReturn != "" || (address_5.addressType == "coordinates")) {
      if(address_5.addressType == "coordinates") {
        var latitude = address_5.latitude;
        var longitude = address_5.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_5 = new GMarker(point, icon_5);
        GEvent.addListener(marker_5, 'click', function() {
          marker_5.openInfoWindowHtml(address_5.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_5' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_5);
        }
          wagmp_map_1_obj.markers.push(marker_5);
          wagmp_map_1_obj.addresses.push(address_5);
          wagmp_map_1_obj.icons.push(icon_5);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_5.addressType == "address") {
      geocoder.getLatLng (
      address_5.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_5.full, '', point);
          var marker_5 = new GMarker(point, icon_5);
          GEvent.addListener(marker_5, 'click', function() {
            marker_5.openInfoWindowHtml(address_5.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_5' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_5);
          }
        } else {
          var noZipAddress = address_5.full.replace((address_5.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_5.full, address_5.zip, point);
                var marker_5 = new GMarker(point, icon_5);
                GEvent.addListener(marker_5, 'click', function() {
                  marker_5.openInfoWindowHtml(address_5.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_5' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_5);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_6 = new GIcon();
    icon_6.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_6.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_6.iconSize = new GSize(34,35);
    icon_6.shadowSize = new GSize(34,35);
    icon_6.iconAnchor = new GPoint(9,33);
    icon_6.infoWindowAnchor = new GPoint(19,0);
    icon_6.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_6.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_6.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_6.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_6 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Pra%C3%A7a_do_Com%C3%A9rcio" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Praça do Comércio</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Situated near the Tagus river, the square is still commonly known as Terreiro do Paço (Palace Square), because it was the location of the Royal Ribeira Palace (Paços da Ribeira) until it was destroyed by the great 1755 Lisbon Earthquake.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/pracacom.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.707515,-9.136355',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.707515',
      longitude: '-9.136355',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_6.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_6.full, address_6.zip);
    }
    if (cacheReturn != "" || (address_6.addressType == "coordinates")) {
      if(address_6.addressType == "coordinates") {
        var latitude = address_6.latitude;
        var longitude = address_6.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_6 = new GMarker(point, icon_6);
        GEvent.addListener(marker_6, 'click', function() {
          marker_6.openInfoWindowHtml(address_6.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_6' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_6);
        }
          wagmp_map_1_obj.markers.push(marker_6);
          wagmp_map_1_obj.addresses.push(address_6);
          wagmp_map_1_obj.icons.push(icon_6);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_6.addressType == "address") {
      geocoder.getLatLng (
      address_6.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_6.full, '', point);
          var marker_6 = new GMarker(point, icon_6);
          GEvent.addListener(marker_6, 'click', function() {
            marker_6.openInfoWindowHtml(address_6.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_6' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_6);
          }
        } else {
          var noZipAddress = address_6.full.replace((address_6.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_6.full, address_6.zip, point);
                var marker_6 = new GMarker(point, icon_6);
                GEvent.addListener(marker_6, 'click', function() {
                  marker_6.openInfoWindowHtml(address_6.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_6' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_6);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_7 = new GIcon();
    icon_7.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_7.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_7.iconSize = new GSize(34,35);
    icon_7.shadowSize = new GSize(34,35);
    icon_7.iconAnchor = new GPoint(9,33);
    icon_7.infoWindowAnchor = new GPoint(19,0);
    icon_7.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_7.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_7.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_7.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_7 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Casa_dos_Bicos" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Casa dos Bicos</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Casa dos Bicos (Portuguese for House of the Spikes) is a historical house in the city of Lisbon, in Portugal. The house, built in the early 16th century in the Alfama neighbourhood, has a curious façade of Renaissance and Manueline influence.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/bicos.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.708997,-9.132600',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.708997',
      longitude: '-9.132600',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_7.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_7.full, address_7.zip);
    }
    if (cacheReturn != "" || (address_7.addressType == "coordinates")) {
      if(address_7.addressType == "coordinates") {
        var latitude = address_7.latitude;
        var longitude = address_7.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_7 = new GMarker(point, icon_7);
        GEvent.addListener(marker_7, 'click', function() {
          marker_7.openInfoWindowHtml(address_7.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_7' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_7);
        }
          wagmp_map_1_obj.markers.push(marker_7);
          wagmp_map_1_obj.addresses.push(address_7);
          wagmp_map_1_obj.icons.push(icon_7);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_7.addressType == "address") {
      geocoder.getLatLng (
      address_7.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_7.full, '', point);
          var marker_7 = new GMarker(point, icon_7);
          GEvent.addListener(marker_7, 'click', function() {
            marker_7.openInfoWindowHtml(address_7.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_7' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_7);
          }
        } else {
          var noZipAddress = address_7.full.replace((address_7.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_7.full, address_7.zip, point);
                var marker_7 = new GMarker(point, icon_7);
                GEvent.addListener(marker_7, 'click', function() {
                  marker_7.openInfoWindowHtml(address_7.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_7' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_7);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_8 = new GIcon();
    icon_8.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_8.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_8.iconSize = new GSize(34,35);
    icon_8.shadowSize = new GSize(34,35);
    icon_8.iconAnchor = new GPoint(9,33);
    icon_8.infoWindowAnchor = new GPoint(19,0);
    icon_8.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_8.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_8.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_8.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_8 = {
      street: 'Av. da Liberdade 2',
      city: 'Lisboa',
      state: '',
      zip: '1150',
      country: 'Portugal',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://www.hardrock.com/locations/cafes3/Cafe.aspx?LocationID=368&amp;MIBEnumID=3" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Hard  Rock Café Lisbon</span></a><br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">It started with an Eric Clapton guitar (a  Fender Lead II, for the gearheads in the audience). The beginning of something  that nobody even knew was beginning.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/hardrock.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: 'Av. da Liberdade 2, Lisboa, 1150, Portugal',
      isdefault: false,
      addressType: 'address',
      loop: '',
      latitude: '',
      longitude: '',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_8.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_8.full, address_8.zip);
    }
    if (cacheReturn != "" || (address_8.addressType == "coordinates")) {
      if(address_8.addressType == "coordinates") {
        var latitude = address_8.latitude;
        var longitude = address_8.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_8 = new GMarker(point, icon_8);
        GEvent.addListener(marker_8, 'click', function() {
          marker_8.openInfoWindowHtml(address_8.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_8' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_8);
        }
          wagmp_map_1_obj.markers.push(marker_8);
          wagmp_map_1_obj.addresses.push(address_8);
          wagmp_map_1_obj.icons.push(icon_8);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_8.addressType == "address") {
      geocoder.getLatLng (
      address_8.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_8.full, '', point);
          var marker_8 = new GMarker(point, icon_8);
          GEvent.addListener(marker_8, 'click', function() {
            marker_8.openInfoWindowHtml(address_8.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_8' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_8);
          }
        } else {
          var noZipAddress = address_8.full.replace((address_8.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_8.full, address_8.zip, point);
                var marker_8 = new GMarker(point, icon_8);
                GEvent.addListener(marker_8, 'click', function() {
                  marker_8.openInfoWindowHtml(address_8.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_8' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_8);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_9 = new GIcon();
    icon_9.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_9.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_9.iconSize = new GSize(34,35);
    icon_9.shadowSize = new GSize(34,35);
    icon_9.iconAnchor = new GPoint(9,33);
    icon_9.infoWindowAnchor = new GPoint(19,0);
    icon_9.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_9.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_9.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_9.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_9 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/National_Museum_of_Ancient_Art" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Museu Nacional de Arte Antiga</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Museu Nacional de Arte Antiga that is located in Lisbon is the most important art museum in Portugal as well as being among the most important in Europe.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/arte.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.704459,-9.162126',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.704459',
      longitude: '-9.162126',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_9.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_9.full, address_9.zip);
    }
    if (cacheReturn != "" || (address_9.addressType == "coordinates")) {
      if(address_9.addressType == "coordinates") {
        var latitude = address_9.latitude;
        var longitude = address_9.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_9 = new GMarker(point, icon_9);
        GEvent.addListener(marker_9, 'click', function() {
          marker_9.openInfoWindowHtml(address_9.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_9' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_9);
        }
          wagmp_map_1_obj.markers.push(marker_9);
          wagmp_map_1_obj.addresses.push(address_9);
          wagmp_map_1_obj.icons.push(icon_9);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_9.addressType == "address") {
      geocoder.getLatLng (
      address_9.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_9.full, '', point);
          var marker_9 = new GMarker(point, icon_9);
          GEvent.addListener(marker_9, 'click', function() {
            marker_9.openInfoWindowHtml(address_9.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_9' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_9);
          }
        } else {
          var noZipAddress = address_9.full.replace((address_9.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_9.full, address_9.zip, point);
                var marker_9 = new GMarker(point, icon_9);
                GEvent.addListener(marker_9, 'click', function() {
                  marker_9.openInfoWindowHtml(address_9.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_9' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_9);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_10 = new GIcon();
    icon_10.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_10.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_10.iconSize = new GSize(34,35);
    icon_10.shadowSize = new GSize(34,35);
    icon_10.iconAnchor = new GPoint(9,33);
    icon_10.infoWindowAnchor = new GPoint(19,0);
    icon_10.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_10.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_10.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_10.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_10 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Museu_Nacional_dos_Coches" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Museu Nacional dos Coches</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The National Coach Museum is located in the Belém district of Lisbon, in Portugal. The museum has one of the finest collections of historical carriages in the world, being one of the most visited museums of the city.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/coches.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.697527,-9.199709',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.697527',
      longitude: '-9.199709',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_10.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_10.full, address_10.zip);
    }
    if (cacheReturn != "" || (address_10.addressType == "coordinates")) {
      if(address_10.addressType == "coordinates") {
        var latitude = address_10.latitude;
        var longitude = address_10.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_10 = new GMarker(point, icon_10);
        GEvent.addListener(marker_10, 'click', function() {
          marker_10.openInfoWindowHtml(address_10.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_10' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_10);
        }
          wagmp_map_1_obj.markers.push(marker_10);
          wagmp_map_1_obj.addresses.push(address_10);
          wagmp_map_1_obj.icons.push(icon_10);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_10.addressType == "address") {
      geocoder.getLatLng (
      address_10.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_10.full, '', point);
          var marker_10 = new GMarker(point, icon_10);
          GEvent.addListener(marker_10, 'click', function() {
            marker_10.openInfoWindowHtml(address_10.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_10' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_10);
          }
        } else {
          var noZipAddress = address_10.full.replace((address_10.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_10.full, address_10.zip, point);
                var marker_10 = new GMarker(point, icon_10);
                GEvent.addListener(marker_10, 'click', function() {
                  marker_10.openInfoWindowHtml(address_10.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_10' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_10);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_11 = new GIcon();
    icon_11.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_11.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_11.iconSize = new GSize(34,35);
    icon_11.shadowSize = new GSize(34,35);
    icon_11.iconAnchor = new GPoint(9,33);
    icon_11.infoWindowAnchor = new GPoint(19,0);
    icon_11.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_11.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_11.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_11.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_11 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Mosteiro_dos_jeronimos" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Mosteiro dos Jerónimos</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Hieronymites Monastery is located in the Belém district of Lisbon, Portugal. This magnificent monastery can be considered one of the most prominent monuments in Lisbon and is certainly one of the most successful achievements of the Manueline style (portuguese late-Gothic).</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/jeronimos.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.697702,-9.207230',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.697702',
      longitude: '-9.207230',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_11.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_11.full, address_11.zip);
    }
    if (cacheReturn != "" || (address_11.addressType == "coordinates")) {
      if(address_11.addressType == "coordinates") {
        var latitude = address_11.latitude;
        var longitude = address_11.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_11 = new GMarker(point, icon_11);
        GEvent.addListener(marker_11, 'click', function() {
          marker_11.openInfoWindowHtml(address_11.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_11' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_11);
        }
          wagmp_map_1_obj.markers.push(marker_11);
          wagmp_map_1_obj.addresses.push(address_11);
          wagmp_map_1_obj.icons.push(icon_11);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_11.addressType == "address") {
      geocoder.getLatLng (
      address_11.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_11.full, '', point);
          var marker_11 = new GMarker(point, icon_11);
          GEvent.addListener(marker_11, 'click', function() {
            marker_11.openInfoWindowHtml(address_11.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_11' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_11);
          }
        } else {
          var noZipAddress = address_11.full.replace((address_11.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_11.full, address_11.zip, point);
                var marker_11 = new GMarker(point, icon_11);
                GEvent.addListener(marker_11, 'click', function() {
                  marker_11.openInfoWindowHtml(address_11.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_11' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_11);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_12 = new GIcon();
    icon_12.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_12.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_12.iconSize = new GSize(34,35);
    icon_12.shadowSize = new GSize(34,35);
    icon_12.iconAnchor = new GPoint(9,33);
    icon_12.infoWindowAnchor = new GPoint(19,0);
    icon_12.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_12.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_12.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_12.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_12 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://mnazulejo.imc-ip.pt/en-GB/default.aspx" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Museu Nacional do Azulejo</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The National Museum of Tiles is one of the most important national museums, for their unique collection, the tiles, artistic expression differential of Portuguese culture, and the odd building in which it is installed, the old Convent of the Mother of God, founded in 1509 by Queen Leonor.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/azulejo.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.724743,-9.113996',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.724743',
      longitude: '-9.113996',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_12.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_12.full, address_12.zip);
    }
    if (cacheReturn != "" || (address_12.addressType == "coordinates")) {
      if(address_12.addressType == "coordinates") {
        var latitude = address_12.latitude;
        var longitude = address_12.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_12 = new GMarker(point, icon_12);
        GEvent.addListener(marker_12, 'click', function() {
          marker_12.openInfoWindowHtml(address_12.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_12' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_12);
        }
          wagmp_map_1_obj.markers.push(marker_12);
          wagmp_map_1_obj.addresses.push(address_12);
          wagmp_map_1_obj.icons.push(icon_12);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_12.addressType == "address") {
      geocoder.getLatLng (
      address_12.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_12.full, '', point);
          var marker_12 = new GMarker(point, icon_12);
          GEvent.addListener(marker_12, 'click', function() {
            marker_12.openInfoWindowHtml(address_12.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_12' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_12);
          }
        } else {
          var noZipAddress = address_12.full.replace((address_12.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_12.full, address_12.zip, point);
                var marker_12 = new GMarker(point, icon_12);
                GEvent.addListener(marker_12, 'click', function() {
                  marker_12.openInfoWindowHtml(address_12.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_12' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_12);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_13 = new GIcon();
    icon_13.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_13.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_13.iconSize = new GSize(34,35);
    icon_13.shadowSize = new GSize(34,35);
    icon_13.iconAnchor = new GPoint(9,33);
    icon_13.infoWindowAnchor = new GPoint(19,0);
    icon_13.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_13.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_13.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_13.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_13 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Padr%C3%A3o_dos_Descobrimentos" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Padrão dos Descobrimentos</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Padrão dos Descobrimentos (Monument to the Discoveries) is a monument that celebrates the Portuguese who took part in the Age of Discovery of the 15th and 16th centuries. It is located on the estuary of the Tagus river in the Belém parish of Lisbon, Portugal, where ships departed to their often unknown destinations.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/descobre.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.693717,-9.205792',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.693717',
      longitude: '-9.205792',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_13.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_13.full, address_13.zip);
    }
    if (cacheReturn != "" || (address_13.addressType == "coordinates")) {
      if(address_13.addressType == "coordinates") {
        var latitude = address_13.latitude;
        var longitude = address_13.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_13 = new GMarker(point, icon_13);
        GEvent.addListener(marker_13, 'click', function() {
          marker_13.openInfoWindowHtml(address_13.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_13' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_13);
        }
          wagmp_map_1_obj.markers.push(marker_13);
          wagmp_map_1_obj.addresses.push(address_13);
          wagmp_map_1_obj.icons.push(icon_13);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_13.addressType == "address") {
      geocoder.getLatLng (
      address_13.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_13.full, '', point);
          var marker_13 = new GMarker(point, icon_13);
          GEvent.addListener(marker_13, 'click', function() {
            marker_13.openInfoWindowHtml(address_13.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_13' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_13);
          }
        } else {
          var noZipAddress = address_13.full.replace((address_13.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_13.full, address_13.zip, point);
                var marker_13 = new GMarker(point, icon_13);
                GEvent.addListener(marker_13, 'click', function() {
                  marker_13.openInfoWindowHtml(address_13.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_13' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_13);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_14 = new GIcon();
    icon_14.image = 'google_javascript/images/traditionalpillow_slate.png';
    icon_14.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_14.iconSize = new GSize(34,35);
    icon_14.shadowSize = new GSize(34,35);
    icon_14.iconAnchor = new GPoint(9,33);
    icon_14.infoWindowAnchor = new GPoint(19,0);
    icon_14.printImage = 'google_javascript/images/traditionalpillow_slate.gif';
    icon_14.mozPrintImage = 'google_javascript/images/traditionalpillow_slate_mozprint.png';
    icon_14.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_14.transparent = 'google_javascript/images/traditionalpillow_slate_transparent.png';

    var address_14 = {
      street: '',
      city: '',
      state: '',
      zip: '',
      country: '',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><a href="http://en.wikipedia.org/wiki/Torre_de_Bel%C3%A9m" target="_blank"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">Torre de Belém</span></a><br />      <br />    <span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;">The Belém Tower was built in the early sixteenth century in the Portuguese late-Gothic style, the Manueline, to commemorate Vasco da Gama\'s expedition.</span></td><br />    <td width="133" align="center" valign="top"><img src="/images/belem.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.691640,-9.215941',
      isdefault: false,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.691640',
      longitude: '-9.215941',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Slate'
    };
    
    if (address_14.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_14.full, address_14.zip);
    }
    if (cacheReturn != "" || (address_14.addressType == "coordinates")) {
      if(address_14.addressType == "coordinates") {
        var latitude = address_14.latitude;
        var longitude = address_14.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_14 = new GMarker(point, icon_14);
        GEvent.addListener(marker_14, 'click', function() {
          marker_14.openInfoWindowHtml(address_14.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_14' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_14);
        }
          wagmp_map_1_obj.markers.push(marker_14);
          wagmp_map_1_obj.addresses.push(address_14);
          wagmp_map_1_obj.icons.push(icon_14);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_14.addressType == "address") {
      geocoder.getLatLng (
      address_14.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_14.full, '', point);
          var marker_14 = new GMarker(point, icon_14);
          GEvent.addListener(marker_14, 'click', function() {
            marker_14.openInfoWindowHtml(address_14.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_14' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_14);
          }
        } else {
          var noZipAddress = address_14.full.replace((address_14.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_14.full, address_14.zip, point);
                var marker_14 = new GMarker(point, icon_14);
                GEvent.addListener(marker_14, 'click', function() {
                  marker_14.openInfoWindowHtml(address_14.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_14' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_14);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }

    var icon_15 = new GIcon();
    icon_15.image = 'google_javascript/images/traditionalpillow_deepjungle.png';
    icon_15.shadow = 'google_javascript/images/traditionalpillow_shadow.png';
    icon_15.iconSize = new GSize(34,35);
    icon_15.shadowSize = new GSize(34,35);
    icon_15.iconAnchor = new GPoint(9,33);
    icon_15.infoWindowAnchor = new GPoint(19,0);
    icon_15.printImage = 'google_javascript/images/traditionalpillow_deepjungle.gif';
    icon_15.mozPrintImage = 'google_javascript/images/traditionalpillow_deepjungle_mozprint.png';
    icon_15.printShadow = 'google_javascript/images/traditionalpillow_shadow.gif';
    icon_15.transparent = 'google_javascript/images/traditionalpillow_deepjungle_transparent.png';

    var address_15 = {
      street: 'Rua 1º de Dezembro 123',
      city: 'Lisboa',
      state: '',
      zip: '1200-359',
      country: 'Portugal',
      infowindow: 'custom',
      infowindowtext: '<span style="font: 12px Verdana, Arial, Helvetica, sans-serif; color: black;"><table width="350" border="0" cellspacing="0" cellpadding="5" height="150"><br />  <tr><br />    <td width="197" align="center" valign="top"><span style="font-family:Verdana, Geneva, sans-serif; font-size:10px;"><strong>HOTEL AVENIDA PALACE<br />    </strong>*****<br />    Rua 1º de Dezembro 123<br />    1200-359 Lisboa<br />    PORTUGAL<br />    </span></td><br />    <td width="133" align="center" valign="top"><img src="/images/palace.gif" width="133" height="143" /></td><br />  </tr><br /></table></span>',
      full: '38.714598,-9.141140',
      isdefault: true,
      addressType: 'coordinates',
      loop: '',
      latitude: '38.714598',
      longitude: '-9.141140',
      markerStyle: 'Google Traditional (pillow)',
      markerColor: 'Deep Jungle'
    };
    
    if (address_15.addressType == "coordinates") {
      var cacheReturn = '';
    } else {
      var cacheReturn = searchCache(address_15.full, address_15.zip);
    }
    if (cacheReturn != "" || (address_15.addressType == "coordinates")) {
      if(address_15.addressType == "coordinates") {
        var latitude = address_15.latitude;
        var longitude = address_15.longitude;
      } else {
        var latitude = cacheReturn.substring(1,cacheReturn.indexOf(",")-1);
        var longitude = cacheReturn.substring(cacheReturn.indexOf(",")+1,(cacheReturn.length)-1);
      }
      var point = new GLatLng(latitude, longitude);
      if (point && !isNaN(latitude)) {
        wagmp_map_1_obj.addressFailed = false;
        var marker_15 = new GMarker(point, icon_15);
        GEvent.addListener(marker_15, 'click', function() {
          marker_15.openInfoWindowHtml(address_15.infowindowtext);
        });
        if(!fromAddress.enabled || 'address_15' != 'address_15') {
          map.setCenter(point, 13);
          map.addOverlay(marker_15);
            marker_15.openInfoWindowHtml(address_15.infowindowtext);
        }
          wagmp_map_1_obj.markers.push(marker_15);
          wagmp_map_1_obj.addresses.push(address_15);
          wagmp_map_1_obj.icons.push(icon_15);
          wagmp_map_1_obj.points.push(point);
        } else {
        if (wagmp_map_1_obj.addressFailed) {
          map.setCenter(new GLatLng(30, -98), 3);
        }
        wagmp_map_1_obj.addressFailed = true;
      }
    } else if (address_15.addressType == "address") {
      geocoder.getLatLng (
      address_15.full,
      function(point) {
        if(point) {
          this.addressFailed = false;
          addToCache(address_15.full, '', point);
          var marker_15 = new GMarker(point, icon_15);
          GEvent.addListener(marker_15, 'click', function() {
            marker_15.openInfoWindowHtml(address_15.infowindowtext);
          });
          if(!fromAddress.enabled || 'address_15' != 'address_15') {
            map.setCenter(point, 13);
            map.addOverlay(marker_15);
            marker_15.openInfoWindowHtml(address_15.infowindowtext);
          }
        } else {
          var noZipAddress = address_15.full.replace((address_15.zip+','), '');
          geocoder.getLatLng (noZipAddress,
            function(point) {
              if(point) {
                wagmp_map_1_obj.addressFailed = false;
                addToCache(address_15.full, address_15.zip, point);
                var marker_15 = new GMarker(point, icon_15);
                GEvent.addListener(marker_15, 'click', function() {
                  marker_15.openInfoWindowHtml(address_15.infowindowtext);
                });
                if (!fromAddress.enabled || 'address_15' != 'address_15') {
                  map.setCenter(point, 13);
                  map.addOverlay(marker_15);
            marker_15.openInfoWindowHtml(address_15.infowindowtext);
                }
              } else {
                if (wagmp_map_1_obj.addressFailed) {
                  map.setCenter(new GLatLng(30, -98), 3);
                }
                  wagmp_map_1_obj.addressFailed = true;
              }
            }
          );
        }
      }
    );
  }


  }
}
