Welcome, Guest. Please login or register.
Did you miss your activation email?
May 27, 2012, 01:07:29 AM

Login with username, password and session length
Search:     Advanced search
Interested in joining the WebsiteBaker team?
For more Information read here or on our new website.
155557 Posts in 21715 Topics by 7737 Members
Latest Member: gx-world
* Home Help Search Login Register
Pages: 1 ... 5 6 [7]   Go Down
Print
Author Topic: Google-Map module  (Read 51998 times)
aldus

Offline Offline

Posts: 1238


« Reply #150 on: January 02, 2011, 03:39:25 PM »

Ok ... for testing ones here an 0.2.0

Kind regards
Aldus
Logged
fsuk

Offline Offline

Posts: 127



« Reply #151 on: January 03, 2011, 02:46:53 PM »

Thanks! Works great.
Logged

You say deviant like its a bad thing...
fsuk

Offline Offline

Posts: 127



« Reply #152 on: January 03, 2011, 02:49:57 PM »

I've noticed that after saving and closing the marker window and then opening it again only the first marker is shown in the list. Is this normal behavior?
Logged

You say deviant like its a bad thing...
aldus

Offline Offline

Posts: 1238


« Reply #153 on: January 03, 2011, 04:43:04 PM »

Hello
Sorry for being late - but have to work out-office theese days ...
As i'm not very familar within the markers and had made some of the last bugfixes it sounds to me as
a "not normal" behavoir at all.

Need a little bit to reproduce this one wink

Kind regards
Aldus
Logged
fsuk

Offline Offline

Posts: 127



« Reply #154 on: January 03, 2011, 05:52:03 PM »

I think the problem is this:

marker.php line 137
Code:
for ($x=1;$x<4;$x++){
$a = isset($max_order) + $x;

}

Changing it to
Code:
for ($x=1;$x<4;$x++){
if(isset($max_order)) $a = $max_order + $x;
else $a = $x;

}
solves the problem.

The problem is isset($max_order) retruns a boolean value 1 or 0 and not the $max_order value if set, this means that only the first marker is shown as the others are overwriten
Logged

You say deviant like its a bad thing...
aldus

Offline Offline

Posts: 1238


« Reply #155 on: January 03, 2011, 06:16:31 PM »

Hm ... that could it be ...
Another way could be a oneliner like
Code:
<?php // not this one ... this line is for the color
for ($x=1;$x<4;$x++){
$a $x + ( true === isset($max_order) ? $max_order );
to keep the line-numbering intact ... but that's my own
If this one works for you we've got an 0.2.1 one wink

Edit
A mutch better one would be to set $max_orders to a valid integer before instead of testing it at last three/four times about
his existance ... e.g. line 125 ff.
Code:
<?php // not this one - please ..
$max_order 0; // #1
$result mysql_query($query);
while($row mysql_fetch_assoc($result)) {
while (list ($key$val) = each ($row)) {
if ($key == 'static') {
$key 'windowbehavior';
}
$example[$row['pointer_order']][$key] = $val;
}
$max_order $row['pointer_order']; // #3
}
for ($x=1;$x<4;$x++){
$a $x $max_order; // #2

Setting in line #1 and simplify line #2 as in #3 the value is "overwirtten" ... would be better and (a littel bit) faster ...

Kind regards
Aldus
« Last Edit: January 03, 2011, 06:36:01 PM by aldus » Logged
aldus

Offline Offline

Posts: 1238


« Reply #156 on: January 03, 2011, 06:49:38 PM »

But to keep it simple and the changes smart i think this one is the best; in line 135 ff. ...
Code:
<?php // not this one
if (!isset($max_order)) $max_order 0; // # 1: give it a valid value
for ($x=1;$x<4;$x++){
$a $x $max_order; // # 2: simple addition
as we are only looking for the var at one time (instead inside the loop) #1 and #2 got a simple addition instead of a complex if_else ...

Kind regards
Aldus
Logged
fsuk

Offline Offline

Posts: 127



« Reply #157 on: January 03, 2011, 10:11:58 PM »

Any of them work fine, but yes the last is slighty more efficient.
Logged

You say deviant like its a bad thing...
aldus

Offline Offline

Posts: 1238


« Reply #158 on: January 04, 2011, 04:56:25 PM »

Thank's for testing it, and, as i wrote, here's an upgrade to the 0.2.1 one.
If there are no new buggs at all the next few day's i'll try to place it on AMASP.

Kind regards
Aldus
Logged
JC

Offline Offline

Posts: 56


« Reply #159 on: April 15, 2011, 10:57:12 PM »

Hi!

First of all I would like to say that I really like this module and think it has great potential! I have only played around with it for an hour or two but I have a question. And hopefully someone will take the time to answer me..  smiley
I wonder if it would be difficult to add a forth option of "Fensterverhalten". For me, and maybe someone else, it would be a good idea to have a "popup-option" that is used as a link. Of course I can type in <a href="">... on all my popup-markers but it seems like a lot of unnecessery work. Especialy when I will have quite a lot of these links..

Kind regards,
JC
Logged
JC

Offline Offline

Posts: 56


« Reply #160 on: April 15, 2011, 11:04:08 PM »

Hi again!

I allready have an additional question to the previus post..
I understand that what I'm about to ask now is a much bigger issue, but if you don't ask you won't get any answers..
How big a project would it be to display markers within this module with the lat- and long-info from another module? Do you understand what I'm asking? If I have already lat- and long-info in the DB from another module, could I then somehow display those as markers on the GoogleMap?

Kind regards,
JC
Logged
TWCrap

Offline Offline

Posts: 4


« Reply #161 on: November 01, 2011, 05:53:01 PM »

Hi,

I'm making an website for somebody, and want's the google map to...

But it doesn't show anything... I get an empty page (only the defualt stuff). but it treis to load the image, becuase there's some space between the top and the bottom...

After some trying, i came accros the following error...

Failed to load resource: the server responded with a status of 404 (Not Found)   http://127.0.0.1:4001/wbdemo/pages/GMAP_MARKER_SEPERATED


Can you tell me an work around or gife me the solution???

Hope to hear soon from you

TWCrap

-PS- srr for bad english Wink
Logged
TWCrap

Offline Offline

Posts: 4


« Reply #162 on: November 02, 2011, 05:04:41 PM »

i´ve looked in the source, and i think that it´s this code that give´s the problem;

Code:
if (defined('GMAP_MARKER_SEPERATED')) {
$marker_seperated = explode('//++//', 'GMAP_MARKER_SEPERATED');
for ($x=0; $x<count($marker_seperated); $x++){
echo '<img src="'.$marker_seperated[$x].'" alt="google_map_marker" style="display:none" />';
}
}

$marker_seperated = explode('//++//', 'GMAP_MARKER_SEPERATED');
for ($x=0; $x<count($marker_seperated); $x++){
echo '<img src="'.$marker_seperated[$x].'" alt="google_map_marker" style="display:none" />';
}

Does somebody knows how to fix the problem???

Thanks
TWCrap
Logged
reschl

Offline Offline

Posts: 6


« Reply #163 on: November 30, 2011, 05:26:33 PM »

hi,

i have a problem with this module version 0.2.1 beta

the map shows up fine in every browser except in internet explorer 8.

in ie8 the content area is blank.

does any one have an advice for me?

(i know, do not use ie, but the customers uses ie8)
Logged
bizzibi

Offline Offline

Posts: 6


« Reply #164 on: March 04, 2012, 06:20:04 PM »

Hallo,

I have installed the latest GoogleMaps-module for the first time and most of it mostely works good for me.

There are still some questions:

1. Please take a look at http://www.gewichtsconsulentelingewaard.nl/pages/contact/route.php and you will see on top of the page echoed: onload="gmapload()" onunload="GUnload()"

Where could this come from? I have looked in functions.php but not located the problem there.

2. Though I have filled in the first Marker-row, there is not shown a marker in the Map.

3. If you are interested for the Install-files I'm working on al dutch translation of the GoogleMap-languagescript.


greetz BizziBi
Logged
Pages: 1 ... 5 6 [7]   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!