Coordinates no map

Phoca Maps - displaying maps in Joomla! CMS
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48398
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Coordinates no map

Post by Jan »

Hi, if there is nothing only blank page then it seems that there is some php error. if you have disabled error reporting try to see error log on your server, maybe you will find there some error.

Jan
If you find Phoca extensions useful, please support the project
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48398
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Coordinates no map

Post by Jan »

Hi, I need to know the error message, so I can take a look at it. Mostly if blank page is displayed, there is some error message but it is not displayed because of e.g. error reporting is off (in php.ini) Try to look at your error log on your server or try to enable debug mode on your Joomla! global configuration so you can get some error message.

Jan
If you find Phoca extensions useful, please support the project
jojo
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 17 Nov 2009, 12:34
Location: France

Re: Coordinates no map

Post by jojo »

Hello,
I had exactly the same problem with Phoca Map component 1.0.4 with Joomla 1.5.14.
After the installation of Phoca Map and the generation of Key API Google Map, all was working fine and I was able to create one map by clicking on the 'coordinate' buttom in the component.
One day after, when I wanted to update my MAP, I always had a blank window after clicking on 'coordinate' button.
As my site was local and the Key API was generated with the future name of the site, I generated again a new key API Google Map for site http://localhost/ and update it in Phoca Map parameters but the problem was the same. I had the problem to update my map and also to create a new one.
.
With the usage of Firebug, I was able to find an error message in the console output.
The error message was "Sorry, server was unable to geocode that address" and came from function 'addAddressToMap' located in file \administrator\components\com_phocamaps\views\phocamapsgmap\tmpl\default.php.
function addAddressToMap(response) {
mapPhocaMap.clearOverlays();
if (!response || response.Status.code != 200)
window.alert('<?php echo JText::_("Sorry, server was unable to geocode that address") ?>');
} else {
place = response.Placemark[0];
...

In fact, I was in the case '!response' but I don't understand why ?
In the Apache log file, I have one http result with return code 200 (OK) when clicking on 'coordinate' buttom
127.0.0.1 - - [25/Nov/2009:11:30:36 +0100] "GET /hockey/administrator/index.php?option=com_phocamaps&view=phocamapsgmap&tmpl=component&lat=47.284178301922665&lng=-1.4812231063842773&zoom=15&type=map HTTP/1.1" 200 6406

To solve my problem, I have updated the default.php file. I put in comments the lines corresponding with the 'if' and only keep the lines of the 'else' case.
After that all is working fine and I am now able to use again the 'coordinate' buttom to 'update' or 'create' a new map.

Perhaps, this information will help others users of Phoca Map which had the same problem.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48398
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Coordinates no map

Post by Jan »

Ok, thank for this information.

Jan
If you find Phoca extensions useful, please support the project
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48398
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Coordinates no map

Post by Jan »

Hi, for now I don't have any solution, I am trying and testing it on different OS/servers and get no such problem :-(
If you find Phoca extensions useful, please support the project
Post Reply