Phoca maps crashes when email address to description

Phoca Maps - displaying maps in Joomla! CMS
daveturner101
Phoca Newbie
Phoca Newbie
Posts: 8
Joined: 23 Nov 2011, 11:29

Phoca maps crashes when email address to description

Post by daveturner101 »

hi,

im a having a strange problem with phoca maps. I'm unable to put email address into the description of a marker. when the map is viewed on site i get an error. if i remove the email address from markers then the map loads and displays ok.

i think it has something to do with joomla converting email addresses into html code so they're clickable.

i don't really want to disable this site-wide as i have contact pages with email address and i'd like them to be clickable, but if there's a way to stop phoca maps from converting the email addresses then i could try that.

has anyone any ideas? i've pasted the error code below. the map appears grey with no map visible and the following code is displayed on the page underneath:

Code: Select all

' }); google.maps.event.addListener(markerPhocaMarker10PlgPM1, 'click', function() { infoPhocaWindow10PlgPM1.open(mapPhocaMapPlgPM1, markerPhocaMarker10PlgPM1 ); }); var phocaImage7PlgPM1 = new google.maps.MarkerImage('http://fusiongda.develsite.co.uk/images/map-icons/republic-of-ireland.jpg'); var phocaPoint11PlgPM1 = new google.maps.LatLng(53.3215833, -6.363129599999979); var markerPhocaMarker11PlgPM1 = new google.maps.Marker({ title:"Fusion Republic of Ireland", icon:phocaImage7PlgPM1, position: phocaPoint11PlgPM1, map: mapPhocaMapPlgPM1 }); var infoPhocaWindow11PlgPM1 = new google.maps.InfoWindow({ content: '
Fusion Republic of Ireland
Unit 292 Beech Road,
Western Industrial Estate,
Dublin 12

Tel: 00 353 1460 0493
Fax: 00 353 1460 0587 

' }); google.maps.event.addListener(markerPhocaMarker11PlgPM1, 'click', function() { infoPhocaWindow11PlgPM1.open(mapPhocaMapPlgPM1, markerPhocaMarker11PlgPM1 ); }); phocaDirServicePlgPM1 = new google.maps.DirectionsService(); phocaDirDisplayPlgPM1 = new google.maps.DirectionsRenderer(); phocaDirDisplayPlgPM1.setMap(mapPhocaMapPlgPM1); phocaDirDisplayPlgPM1.setPanel(document.getElementById("phocaDirPlgPM1")); google.maps.event.addDomListener(tstPhocaMapPlgPM1, 'DOMMouseScroll', CancelEventPhocaMapPlgPM1); google.maps.event.addDomListener(tstPhocaMapPlgPM1, 'mousewheel', CancelEventPhocaMapPlgPM1); } } function setPhocaDirPlgPM1(fromPMAddressPlgPM1, toPMAddressPlgPM1) { var requestPlgPM1 = { origin: fromPMAddressPlgPM1, destination:	toPMAddressPlgPM1, travelMode: google.maps.DirectionsTravelMode.DRIVING }; phocaDirServicePlgPM1.route(requestPlgPM1, function(responsePlgPM1, statusPlgPM1) { if (statusPlgPM1 == google.maps.DirectionsStatus.OK) { pPIPlgPM1 = document.getElementById('phocaMapsPrintIconPlgPM1'); pPIPlgPM1.style.display='block'; var from64PlgPM1 = Base64.encode(fromPMAddressPlgPM1).toString(); var to64PlgPM1 = Base64.encode(toPMAddressPlgPM1).toString(); pPIPlgPM1.innerHTML = 'Print Route
'; phocaDirDisplayPlgPM1.setDirections(responsePlgPM1); } else if (google.maps.DirectionsStatus.NOT_FOND) { alert("One of the locations specified in the requests's origin, destination, or waypoints could not be geocoded."); } else if (google.maps.DirectionsStatus.ZERO_RESULTS) { alert("No route could be found between the origin and destination."); } else if (google.maps.DirectionsStatus.MAX_WAYPOINTS_EXCEEDED) { alert("Too many DirectionsWaypoints were provided in the DirectionsRequest."); } else if (google.maps.DirectionsStatus.OVER_QUERY_LIMIT) { alert("Webpage has sent too many requests within the allowed time period."); } else if (google.maps.DirectionsStatus.INVALID_REQUEST) { alert("The provided DirectionsRequest was invalid."); } else if (google.maps.DirectionsStatus.REQUEST_DENIED) { alert("Webpage is not allowed to use the directions service."); } else if (google.maps.DirectionsStatus.UNKNOWN_ERROR) { alert("Directions request could not be processed due to a server error. The request may succeed if you try again."); } else { alert("Directions request could not be processed due to a server error. The request may succeed if you try again."); } }); } function initializePlgPM1() { tstPhocaMapPlgPM1.setAttribute("oldValuePlgPM1",0); tstPhocaMapPlgPM1.setAttribute("refreshMapPlgPM1",0); tstIntPhocaMapPlgPM1 = setInterval("CheckPhocaMapPlgPM1()",500); } google.setOnLoadCallback(initializePlgPM1); //]]>
daveturner101
Phoca Newbie
Phoca Newbie
Posts: 8
Joined: 23 Nov 2011, 11:29

Re: Phoca maps crashes when email address to description

Post by daveturner101 »

it seems the problem i'm having is mentioned in this thread: viewtopic.php?f=38&t=16468
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48402
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Phoca maps crashes when email address to description

Post by Jan »

Ok
If you find Phoca extensions useful, please support the project
Post Reply