Welcome, Guest. Please login or register.
March 21, 2010, 03:44:26 PM

Login with username, password and session length
Search:     Advanced search
WB 2.8.1 released!
Download and additional information are available here .
110600 Posts in 15971 Topics by 9314 Members
Latest Member: Linuxkommunist
* Home Help Search Login Register
+  WebsiteBaker Community Forum
|-+  English
| |-+  Modules (Moderators: Argos, BerndJM)
| | |-+  Google-Map module
Pages: [1] 2 3 ... 6 Go Down Print
Author Topic: Google-Map module  (Read 39983 times)
afbelow

Offline Offline

Posts: 43


« on: September 21, 2006, 02:18:56 PM »

Ahoi Ladies,

only if someone want to have a look, but it's not a stable or RC yet.
You find it here.

Dear Klaus and Matthias,
dont worry, it is for this time the last module, which I trouble you with. The others must earn some money, before we release them under GPL.
As you know, I unfortunately cannot test it with Microsoft server, so its on you…
So sorry about.

AFBelow

PS:
Do you think, that there is a way to create in wb3 a integration for function inclusion into page modules, as this exists for snippet modules? As we need e.g. for the Google-Map module.
« Last Edit: January 03, 2007, 04:30:50 PM by afbelow » Logged

kweitzel
Forum administrator
*****
Offline Offline

Posts: 5561


WWW
« Reply #1 on: September 21, 2006, 03:47:31 PM »

Diesmal auf dem 1.4 XAMPP getestet, aber auch auf dem 1.3er nicht besser.

OK ... installation OK ... aber keine Bildausgabe nach der Konfiguration. Der gerenderte Code ist:

Code:
<img src='GMAP_MARKER_SEPERATED' style='display:none'><div id="map" style="width: 200px; height: 200px"></div>

Darin fehlen die Hochkommata (") .. für mich sieht es auf die Schnelle so aus, als ob deswegen auch die variable nicht konvertiert wird.


Bei Editieren der "Marker" auch folgender Fehler (ich denke die liegen hier am setup), bei der älteren Version kommt nur der session_start Fehler:

Code:
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at C:\xampp\xampp\htdocs\wb\modules\gmap\marker.php:9) in C:\xampp\xampp\htdocs\wb\framework\initialize.php on line 57

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at C:\xampp\xampp\htdocs\wb\modules\gmap\marker.php:9) in C:\xampp\xampp\htdocs\wb\framework\initialize.php on line 57

Gruß

Klaus
Logged

http://www.weitzel.biz
PM has been disabled
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #2 on: September 21, 2006, 04:27:35 PM »

Hello,

great modul, got it working on my homepage (http://www.familie-gallas.de) but had the same problem with the editing of the marker. Also the lines didn't seem to work.

Keep on rockin and if this issues are fixed you can be shure we will release this on the addons repository.

Thanks for your work for WB

Matthias
Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
afbelow

Offline Offline

Posts: 43


« Reply #3 on: September 21, 2006, 04:54:43 PM »

The
Quote
<img src='GMAP_MARKER_SEPERAT ED' style='display:none'>
shouldn't not stop the Google API. It can't handle the variable because you haven't defined a marker yet. It isn't nice, but its no problem.

But there are some other problems with XAMPP:
1. XAMPP has excluded some php-functions because windows systems cant handle them. One of these, we need is iconf(). Otherwise we can't handle some XML-HTTP-Requests. At the moment i've no idea for a workaround  undecided
2. PHP for Windows has some php-functions integrated in an other way as PHP for Unix/Linus because of the other way Windows handles pathes. I'm not sure, but i think this might be one of your problems. We will find a workaround for this problem .

The easiest way to fix all these bugs is to take all your WindyBug XP Systems and send them back to unkle Bill...  evil

thanks so far. we're working on...

AFBelow
Logged

kweitzel
Forum administrator
*****
Offline Offline

Posts: 5561


WWW
« Reply #4 on: September 21, 2006, 05:12:10 PM »

grin ... for Servers I completly agree with you ... but unfortunatly not yet for the clients sad

Don't worry about the XAMPP Package, we know, that it doesn't work, that's fine with me.

On Matthias page it does work, unfortunatly on mine (1und1) not ... I put under it a codepage with the php information.

[Edit: Link removed]

cheers

Klaus
« Last Edit: February 09, 2009, 07:20:05 AM by kweitzel » Logged

http://www.weitzel.biz
PM has been disabled
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #5 on: September 22, 2006, 11:13:14 AM »

Hello,

Attached you find version 0.8 of this fantastic modul:

Changelog:
- changed some double and single quotes to get cleaner output code
- deleted some not necessary database connects in a few files
- fixed error messages with "headers already sent by ..."
- stored all files unix konform
- changed all copyright notices from 2005 to 2006
- changed in info.php version to 0.8

So Klaus can you pleas test if this version works for you?

Have fun

Matthias

Edit:
Newer version some posts below

« Last Edit: September 22, 2006, 01:43:42 PM by ruebenwurzel » Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
afbelow

Offline Offline

Posts: 43


« Reply #6 on: September 22, 2006, 11:48:55 AM »

Hi Matthias,

if my daughter asks, where her computer is gone, do not tell her, that it is located here in the server-rack... but now I have a XP for testing  rolleyes

On Linux-Systems we had no problems, neither before nor now, but on XP+XAMPP.
We made a clean installation of XAMPP 1.4.15 and WB 1.6.4 an it isn't running.

I got three messages by the debug system:
Quote
Fehler: ',' oder '{' erwartet, aber '*' gefunden.  Regelsatz wegen ungültigem Selektor ignoriert.
Quelldatei: http://192.168.0.113/test/pages/tango.php
Zeile: 13
That very OK, it's the VML workaround for MS IExplorer
Quote
Fehler: syntax error
Quelldatei: http://192.168.0.113/test/pages/tango.php
Zeile: 35, Spalte: 30
Quelltext:
  userIcon.iconSize=new GSize(,);
Thats the path problem I described yesterday.
Quote
Fehler: gmapload is not defined
Quelldatei: http://192.168.0.113/test/pages/tango.php
Zeile: 1
Of course not. No userIcon -> no function.
And I had to exclude iconv() in marker.php by if(function_exists(iconv), but by doing this I get some problems with the definition of popus to describe the markers.

So I think, it's all the same as yesterday angry

so far
AFBelow
« Last Edit: September 22, 2006, 01:14:04 PM by afbelow » Logged

afbelow

Offline Offline

Posts: 43


« Reply #7 on: September 22, 2006, 12:42:18 PM »

Ahoi,

try the attached one, here it seems to run on XP/XAMPP, but I havent tested all other enviroments yet. And I havent solved the iconv-problem.

by the way: In a few days I should think about deleting markers and waypoints. grin

AFBelow


Edit:
Newer version some posts below

« Last Edit: January 03, 2007, 04:26:30 PM by afbelow » Logged

ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #8 on: September 22, 2006, 12:45:48 PM »

Hello,

be shure i don't tell your daughter what her father has done  grin  grin  grin

My lokal Machine has a XP Pro SP2 system. I don't use XAMPP. I have manually installed and configured my lokal Webserver wich is at the moment Apache 2.0.59, MySql 4.0.26, PHP 4.4.3. I use this because this are the same versions as on my hosted webserver. And with this configuration i don't have any problems with installing and using the google map modul on my lokal webserver.

I don't like XAMPP because it always trys to use the latest versions of the above described modules. This is at the moment i think Apache 2.2x, Mysql 5x and PHP 5x. These modules are on let me say 99% of the hosted servers not available and so it makes no sense to use this as a test enviroment for homepages. I think the errors you have came from this "to new" modules and not from the XP machine.

But you are right there are differences between Linux and Windows sytems with the definitions of pathes and line brakes (\n) wich you use a lot in your google map modul.

So have fun  grin  grin with testing on your daughters XP Webserver and before you got grey hairs bring it back.

Matthias
Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
afbelow

Offline Offline

Posts: 43


« Reply #9 on: September 22, 2006, 01:07:12 PM »

I do not like even Windows. In the office I exclusively work with Unix / Linux machines, also as workstations. Only the Web-Dev-Team has an IE via WINE. Then there are a few Apple for video cut. So for what do I need Windows?

But who in heaven programs Sims2 and such games for Linux for my little dwarf?

There are many in here programming on XP/XAMPP and also for these the module should be functionable more or less.

What about Klaus, did he already test it?
Then we would be with html2pdf and Google-Map for this week through and I could slowly begin, to look pleased on my weekend.

AFBelow
Logged

kweitzel
Forum administrator
*****
Offline Offline

Posts: 5561


WWW
« Reply #10 on: September 22, 2006, 01:36:56 PM »

Hi Folks, sorry, at the moment not too much time ... I'm evaluating some Network management Software for a client ... business *SIGH*

Hope I find some time over the weekend ...

cheers

Klaus

PS: I only run windooze on my Laptop and Workstation (because of my customers) ... and with it XAMPP because it is quick to setup. On my Servers are Fedore Core or BSD ... OK, one Server is Windooze, but only because of Blackberry Enterprise Server (BES) sitting on top of Lotus Domino ... not available for Linux, the BES.
Logged

http://www.weitzel.biz
PM has been disabled
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #11 on: September 22, 2006, 01:41:24 PM »

Hello,

attached you find version 0.10.

Changelog:
- added complete htmlcode to marker.php, routes.php and show_icons.php
- minor fix with double quotes in show_icons.php
- set version to 0.10.

Have fun.

Matthias

Edit:
Newer version some posts below
« Last Edit: September 23, 2006, 02:19:37 PM by ruebenwurzel » Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
maxbrax

Offline Offline

Posts: 59



WWW
« Reply #12 on: September 22, 2006, 02:51:49 PM »

Hi, I have tested GMAP v.0.8 - 0,9 and 1.0  but the result is always negative. 

I have inserted all the data correctly demands comprised the “GoogleMap API-Key (v2)” but the result is always one page without contents.   
http://www.maxbrax.com/pages/map.php
In the page map of google does not appear and in HTML i see a variable GMAP_MARKER_SEPERAT ED that it does not come translate from the PHP parser.
     
Quote
<h2 class="page-title">  MAXBRAX.COM - Map </h2>
</div>
<div class="page-content">
<img src="GMAP_MARKER_SEPERAT ED" style="display:none"><div id="map" style="width: 344px; height: 233px"></div></div>
<div class="post-footer">&nbsp;</div>
</div>
</div>


I have realized a page HTML with the code indicated from Google at time of registation in order to obtain the GoogleMap API-Key and the map shows OK.
seee http://www.maxbrax.com/pages/home.php

Where it is that mistake?  , thanks in advance for the aid
Logged

afbelow

Offline Offline

Posts: 43


« Reply #13 on: September 22, 2006, 03:05:05 PM »

Don't forget to modify your template as described in the helpfile.
... I know, it's friday afternoon.  wink

Notice:
Do not consider the
Quote
<img src="GMAP_MARKER_SEPERAT ED" style="display:none">
.
That means nothing, it is not displayed in your browser as the style-tag says. It's only necessary to handle some bugs of the MS IExplorer cach while the IE is executing the javascript API.
« Last Edit: September 22, 2006, 03:11:40 PM by afbelow » Logged

maxbrax

Offline Offline

Posts: 59



WWW
« Reply #14 on: September 22, 2006, 03:30:26 PM »

 rolleyes
thank afbelow ,  its work now  grin.


Logged

afbelow

Offline Offline

Posts: 43


« Reply #15 on: September 22, 2006, 04:08:51 PM »

OK,
I've updated my server, so we stay on the same version.

Dear Matthias,
while you've "stored all files unix konform" all the german special characters where broken. e.g. in the Helpfile.
But don't worry about, for the moment it's weekend and I go sailing now!

See you on monday.
AFBelow
Logged

ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #16 on: September 22, 2006, 04:21:23 PM »

@afbelow

the "broken" german special chars has nothing to do i think with the way of storing the file. As long as your template uses Charset Iso 8859-1 all is ok. If you have a template with UTF8 wich is the standard charset of WB the special chars could not be displayed. Could also be that your browser has a wrong charset option.

Happy sailing

Matthias
Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
pcwacht
Guest
« Reply #17 on: September 22, 2006, 09:14:11 PM »

Installed 0.10 in xampp:
 ApacheFriends XAMPP (basic package) version 1.4.15
  + Apache 2.0.54
  + MySQL 4.1.13
  + PHP 4.4.0 + PEAR
  + ADODB 4.65

Got me a map api id and installed the module
changed the template according to help
Inserted this as first lines
Code:
<?php include(WB_PATH.'/modules/gmap/functions.php'); ?>
<?php if(SHOW_GOOGLEMAP) {
   gmap_doctype();
} else { 
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?php ?>
and this at ending of head section:
Code:
<?php gmap_setup(); ?>
</head>
<body <?php gmap_bodytag(); ?>>

Showed the gmap page after setting the settings in admin

Error showed on screen: (on every page, allso the non gmap pages)
Code:
Warning: Missing argument 1 for gmap_bodytag() in E:\xampp\htdocs\wb260\modules\gmap\functions.php on line 217
onload="gmapload()" onunload="GUnload()">

Here is the source for the sections involved:
doctype:
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:v="urn:schemas-microsoft-com:vml">
<head>
And the end of head and body cal: (api number changed ofcourse)
Code:
<script src="http://maps.google.com/maps?file=api&amp;v=2&key=place_where_original_key_was_put"
 type="text/javascript"></script><script type="text/javascript">
//<![CDATA[
function gmapload() {
  if (GBrowserIsCompatible()) {

// setting up the Map
  var map = new GMap2(document.getElementById("map"));
  map.setCenter(new GLatLng(52.15371445951162, 5.4217529296875), 5, G_NORMAL_MAP);
  map.addControl(new GLargeMapControl());
  map.addControl(new GMapTypeControl());
  map.addControl(new GOverviewMapControl(), new GControlPosition(G_ANCHOR_BOTTOM_RIGHT, new GSize(0, 0)));

      }
    }
    //]]>
    </script>
</head>
<body <br />
<b>Warning</b>:  Missing argument 1 for gmap_bodytag() in <b>E:\xampp\htdocs\wb260\modules\gmap\functions.php</b> on line <b>217</b><br />
onload="gmapload()" onunload="GUnload()">


Hope this helps debugging.

The example from google api page worked
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <title>Google Maps JavaScript API Example</title>
    <script src="http://maps.google.com/maps?file=api&amp;v=2&amp;key=again_just_filling_the_keyspace"
      type="text/javascript"></script>
    <script type="text/javascript">
    //<![CDATA[
    function load() {
      if (GBrowserIsCompatible()) {
        var map = new GMap2(document.getElementById("map"));
        map.setCenter(new GLatLng(37.4419, -122.1419), 13);
      }
    }
    //]]>
    </script>
  </head>
  <body onload="load()" onunload="GUnload()">
    <div id="map" style="width: 500px; height: 300px"></div>
  </body>
</html>

John

« Last Edit: September 22, 2006, 09:18:16 PM by pcwacht » Logged
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #18 on: September 22, 2006, 11:21:12 PM »

Hello John,

try replacing the following code in the index.php of the template:

This is wrong
Code:
<?php gmap_bodytag(); ?>

This should work
Code:
<?php gmap_bodytag(''); ?>

There seems to be an error in the helpfile. Please post if this works for you.

Matthias
Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #19 on: September 23, 2006, 11:23:20 AM »

Hello John,

did you tested the code?

Matthias
Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
pcwacht
Guest
« Reply #20 on: September 23, 2006, 11:55:11 AM »

That did it.
Code:
<body <?php gmap_bodytag(''); ?>>

Now it is working smooth in xampp.

John
Logged
pcwacht
Guest
« Reply #21 on: September 23, 2006, 12:16:03 PM »

Ok, been playing with this nifty module and I must admin I like it a lot...
Cheers for developing Wink


Few suggestions though,
in modify.php I have increased the input sizes for longitude and latitude so entering goes smoother
lines 83 and 88, changed
size="20"  to size="21"

Allso increased the Zoomlevel to max
changed line 97
from          for ($x=0;$x<18;$x++){
to          for ($x=0;$x<20;$x++){

All is working like a charm now.

Allso the help needs to be updated to include the quotes.

John
« Last Edit: September 23, 2006, 12:18:16 PM by pcwacht » Logged
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #22 on: September 23, 2006, 02:18:21 PM »

Hello,

Thanks John. Attached you find version 0.11 of this modul.

Changelog:
- fixed helpfile
- minor modifications of the modify.php (like john described)

Have fun

Matthias

Edit:
Newer version some posts below.
« Last Edit: September 23, 2006, 03:55:13 PM by ruebenwurzel » Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
pcwacht
Guest
« Reply #23 on: September 23, 2006, 03:24:57 PM »

Installed latest version on Linux
http://www.ictwacht.nl/pages/googlemap.php

When adding a page I get
Unknown column 'lat' in 'field list'

Though everything works

Think a type in add.php?
line 25 change `lat` to `lati`
Code:
// Insert an extra row into the database
$database->query("INSERT INTO ".TABLE_PREFIX."mod_googlemap (`section_id`,`page_id`,`type`,`text`,`pointer_id`,`lat`,`long`,`infowindow`,`static`) VALUES ('$section_id','$page_id','','','','0','0','', '0')");

John
Logged
ruebenwurzel
Leaders Team
*****
Offline Offline

Posts: 7211


Keep on Rockin


WWW
« Reply #24 on: September 23, 2006, 03:53:44 PM »

Hello,

hmmm if you got an error because of "lati" you also shoud get an error because of "longi". This seems to be the same typo.

Fixed both and attached the new version 0.12.

Thanks John

Matthias

Edit:
Newer versio n available at the addons repository
« Last Edit: September 26, 2006, 01:51:12 PM by ruebenwurzel » Logged

You search for help, please look here: Help-Page
You search for Modules, Templates or Languages, please look here: Addons-Page
Pages: [1] 2 3 ... 6 Go Up Print 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!