Phoca Maps size of modalbox to small for the map

Phoca plugins - support for all Phoca plugins except Phoca Gallery plugins
immi1971
Phoca Newbie
Phoca Newbie
Posts: 9
Joined: 01 Sep 2009, 08:39
Location: Germany

Phoca Maps size of modalbox to small for the map

Post by immi1971 »

Hi there,

I'm trying to use the plugin. The problem is that the modalbox is too small. Can I change the size of the modal box which shows the map?

Thanks in advance
Thorsten

you can find the problem at the front page of http://www.ttveuskirchen.de
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48402
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Phoca Maps size of modalbox to small for the map

Post by Jan »

Hi, if you set the map width and height in parameters, the modal box will fit this size.

Jan
If you find Phoca extensions useful, please support the project
njjacob
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 20 Jun 2008, 21:14

Re: Phoca Maps size of modalbox to small for the map

Post by njjacob »

Jan please explain.. there no MODAL parameters. Only the MAIN map size. I even through the Modal MAP in a DIV sized what I needed and it ignores it. Same with the TABLE size. Under the Map Pluin there are no parameters for size.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48402
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Phoca Maps size of modalbox to small for the map

Post by Jan »

Hi, the plugin gets the information from the map,

Code: Select all

$button->set('options', "{handler: 'iframe', size: {x: ".$tmpl['windowwidth'].", y: ".$tmpl['windowheight']."}, overlayOpacity: ".$tmpl['mboverlayopacity'].", classWindow: 'phocamaps-plugin-window', classOverlay: 'phocamaps-plugin-overlay'}");

Code: Select all

if ($mapp->width > 0) {
								$tmpl['windowwidth'] = (int)$mapp->width + 20;
							} else {
								$tmpl['windowwidth'] = 640;
							}
							if ($mapp->width > 0) {
								$tmpl['windowheight'] = (int)$mapp->height + 20;
							} else {
								$tmpl['windowheight'] = 360;
							}

Code: Select all

$query = 'SELECT a.*,'
							. ' CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(\':\', a.id, a.alias) ELSE a.id END as slug'
							.' FROM #__phocamaps_map AS a'
							.' WHERE a.id = '.(int) $idMap;
							$db->setQuery($query);
							$mapp = $db->loadObject();

So the size is set in Maps - in the component and such is taken from the plugin - (you can customize it in plugin)

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