Member
Member
vincent3569   15-11-2010, 22:37
#1

hello

I'm trying to implement google_map plugin on my web site.
I don't understand something :
in image page, I used this following code
`

``

all is OK,the google map is displayed for the only picture which is geolocalized.

But, in the album page, I used this following code

``

``

and nothing is displayed when I have an geolocalized image in the album.

what'is the matter with this function ?`

Member
Member
vincent3569   16-11-2010, 00:06
#2

hello

I think I've found the problem

in google_map.php, there are the following functions :

line 170 : function printImageMap($zoomlevel=NULL, $defaultmaptype=NULL, $width=NULL, $height=NULL, [b]$text=NULL[/b], $toggle=true, $id='googlemap', $mapselections=NULL, $addwiki=NULL, $background=NULL, $mapcontrol=NULL, $maptypecontrol=NULL, $customJS=NULL)

line 252 : function printAlbumMap($zoomlevel=NULL, $defaultmaptype=NULL, $width=NULL, $height=NULL, [b]$text=''[/b], $toggle=true, $id='googlemap', $firstPageImages=0, $mapselections=NULL, $addwiki=NULL, $background=NULL, $mapcontrol=NULL, $maptypecontrol=NULL, $customJS=NULL)

in function printImageMap, there is $text=NULL, and in function printAlbumMap, there is $text=''.

in the first case, if you write in your theme, a "Google Map" link is displayed :

`Google Map

`
but, in the second case, if you write in your theme, an empty link is displayed :

`

`
Do you think I'm right ?

Administrator
Administrator
acrylian   16-11-2010, 11:33
#3

You know that these things like $text are parameters you can or should set? I am not familiar with this plugin at all but there are probably also some options on the backend.

Member
Member
vincent3569   17-11-2010, 07:56
#4

hello

yes of course, you can set this parameter (only in the call of the function and not in the back end).
but if you don't do that, there is a default display.

in the two case, the default display is 'Google Map', but with printAlbumMap(), you have this code (line 313) :
if (is_null($text)) $text = gettext('Google Map');
and the default value for $text is ''.
so the default value is never displayed.

maybe you should set this code :
function printAlbumMap($zoomlevel=NULL, $defaultmaptype=NULL, $width=NULL, $height=NULL, [i]$text=NULL[/i], [...] and everything will be ok

Administrator
Administrator
acrylian   17-11-2010, 10:22
#5

Sorry, although its an official plugin I neiter used ever it nor I am familar with it. My collegue sbillard probably knows more.

Member
Member
sbillard   17-11-2010, 19:34
#6

The parameter default should, of course, be NULL, not ''. We will correct that.

Member
Member
vincent3569   17-11-2010, 19:43
#7

thanks !!

Member
Member
vincent3569   19-11-2010, 23:23
#8

you need a ticket in ZenPhoto trac or not ?

Member
Member
kagutsuchi   20-11-2010, 04:56
#9

The parameter issue was already fixed in SVN in changeset [6177].

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.