Jump to content

Extension talk:Maps/Flow archive/2010

Add topic
From mediawiki.org
Latest comment: 15 years ago by Jeroen De Dauw in topic Beta problem

Google Maps compatible language codes

[edit]

In reply to the discussion here:

Arods mapping will be part of 0.6, I just added them :) Jeroen De Dauw 12:34, 14 April 2010 (UTC)Reply

[maps] Searching for coordinate does not work properly

[edit]

Shalom,

I tried the search term: Coor1::32N, 35W in special:ask, and got two results, one that has coor1:: 32,34 and the other that has coor1:: 32,35. This was done on the current release, as well as on the 0.6R2, with the same results.

Also, searching for a value "greater then" or "less then" seams to ignore the longitude and use only the latitude. [maps] Searching for coordinate does not work properly 09:10, 13 May 2010 (UTC)

I will have a look at the special:ask issue.
The "greater then" and "less then" operators are not supported in any way by Semantic Maps, as it would simply not make sense, and are using SMW's default implementation. Jeroen De Dauw 16:20, 13 May 2010 (UTC)Reply
Thanks. I think support of the greater then operators is critical to anable search within a specific area. 192.115.113.40 18:02, 15 May 2010 (UTC)Reply
In most cases you can simply use the distance query for this.
Anyway, I added very simple support for these operators to Semantic Maps, so both lat and lon should be held into account now :) Jeroen De Dauw 22:33, 15 May 2010 (UTC)Reply
Thanks a lot! Are the greater than and less-than operators supported now? where can I download the most recent update? 62.0.2.244 07:31, 25 May 2010 (UTC)Reply
You can get the code from trunk on svn. Not recommended for production use. If you need this for some serious wiki, just wait until 0.6 is released, which should be soon. Jeroen De Dauw 10:42, 25 May 2010 (UTC)Reply

Custom Coordinate systems?

[edit]

I am interested in the maps extension and its possible uses for mapping fictitious places. Is there a way to apply a completely different coordinate paradigm such as x y coordinates from a game, or decimal sectors from an arbitrary map such as middle earth. TwinHerder 00:30, 20 May 2010 (UTC)Reply

Maps does not currently support this, but it'd definitely the most requested feature. It would not be that hard to add (a few days work at most). The problem is that no one has come forward to fund the development of it yet. Jeroen De Dauw 00:53, 20 May 2010 (UTC)Reply
How much do you think it would cost?
Can you give a description of what a feature like that would work like, and how a custom map would have to be set up (just a directory of tiles, properly labeled?) TwinHerder 19:14, 20 May 2010 (UTC)Reply
That really depends on what you exactly want to be able to do, and with which mapping service. The easiest approach would be to just work with a single image. Only if you have a really huge space, like in a game world, you'd need to have server side tile rendering. Working with just one image won't take very long to implement, like I sated before, it should not take more then a few days. Multiply that by €50/h and you have my estimate. Jeroen De Dauw 13:25, 21 May 2010 (UTC)Reply

Unable to call MapsDisplayMap::initialize()

[edit]

Trying to install Maps on PHP 5.2.0 gives the following error:

Warning: call_user_func(MapsDisplayMap::initialize) [function.call-user-func]: Unable to call MapsDisplayMap::initialize() in .../extensions/Maps/Features/Maps_ParserFunctions.php  on line 38

Warning: call_user_func(MapsDisplayPoint::initialize) [function.call-user-func]: Unable to call MapsDisplayPoint::initialize() in .../extensions/Maps/Features/Maps_ParserFunctions.php on line 38

This is due to the lines 37-39 (in 0.6 rc3, r67115):

		foreach ( $egMapsFeatures['pf'] as $hook ) {
			call_user_func( $hook );
		}

which will result in calls like call_user_func('MapsDisplayPoint::initialize') which is a format supported by PHP 5.2.3+ only (as opposed to call_user_func(array('MapsDisplayPoint', 'initialize')) which works in PHP 5.*).

Quick workaround:

		foreach ( $egMapsFeatures['pf'] as $hook ) {
			if ( strpos( $hook, '::' ) !== false ) {
				$hook = explode( '::', $hook );
			}
			call_user_func( $hook );
		}

Tgr 07:34, 31 May 2010 (UTC)Reply

Thanks for that! Just in time to have it in 0.6 :) Jeroen De Dauw 14:46, 31 May 2010 (UTC)Reply

Error in 0.6 Maps_Settings.php

[edit]

$egMapsOLLayerDependencies 'osm' should read src='$egMapsScriptPath/Services/OpenLayers/OSM/OpenStreetMap.js

if you're wondering why OSM maps don't display :-) 217.171.129.68 18:57, 2 June 2010 (UTC)Reply

Oh ofcourse! Hard to keep track of all these references when making so many changes... :(
Thanks for pointing this out. Jeroen De Dauw 23:59, 2 June 2010 (UTC)Reply

Status with service link?

[edit]

According to http://semantic-mediawiki.org/wiki/Help:Service_links we can set up an online maps service link. However, this does not appear to work as the params are not being evaluated. I can't find the code for this anywhere. What's the status? 217.171.129.74 10:17, 7 June 2010 (UTC)Reply

This features has temporary been disabled. Semantic Maps has it's own mechanism that allows for something similar though. What exactly do you want to do? Jeroen De Dauw 02:03, 8 June 2010 (UTC)Reply
set up links to display a map of a particular coordinate in a separate page.
The disadvantage of embedding maps in a wiki page is that it slows down the loading of the page, so to speed things up an alternative is to have a link to open a map in a separate tab/window. If you just have one, you can simply put that in a standard template, but if you have several different mapbases or, for example, if you want to combine the display with data from other sources, then the service link provides an inbuilt 'popup' for users to choose which one they want. 217.171.129.74 10:36, 8 June 2010 (UTC)Reply
I see... You can not do this with Semantic Maps 0.6 unfortunately. I have added the re-introducing of service links for the new geographical coordinates data type as a to-do for one of the upcoming minor releases. Jeroen De Dauw 11:04, 8 June 2010 (UTC)Reply
On the to-do list for 0.6.4 :) Jeroen De Dauw 13:55, 23 June 2010 (UTC)Reply

New feature to add KML files

[edit]

I tested over the weekend and I basically tweaked the Maps and Semantic Maps extensions to have the ability to include KML files.

Example: http://www.transitunlimited.org/Metrolink#Map

The KML file provides lines, which dramatically improved the appearance and usefulness of the map.

The code for including the map is basically unchanged, except to use kml=http://XXX.com/XXX.kml to show KML file. Basically I use My Maps to draw the lines and link it directly from Google.

I can also use KML to provide image overlay: http://www.transitunlimited.org/California_Academy_of_Sciences

Please let me know if you want the new code. I added it on version 0.6.2, but I guess you can take the extra code and add it on the newer version. 67.170.217.247 07:40, 29 June 2010 (UTC)Reply

I'd be very happy to add your code to Maps, as it's indeed very useful for a lot of people :) You can email it to me? Jeroen De Dauw 13:32, 29 June 2010 (UTC)Reply
I hope you got that email 67.170.217.247 08:21, 1 July 2010 (UTC)Reply
I modified the code to include the functionality you added. The only noticeable difference is that the search bar is treated as a map control, and is not automatically added. You can achieve this behaviour by adding 'searchbar' to $egMapsGMapControls in your localsettings file.
Everything seems to be working, but it'd be great if you could try out what's on svn trunk (0.6.4 a4) and confirm this.
Thanks for the patch :) Jeroen De Dauw 11:45, 1 July 2010 (UTC)Reply
Hi. I see that the code in the trunk allows multiple KMLs, which I think it is even better.
By the way, if you enable the searchbar, the searchbar would cover the scale. It is a known bug with the Google Maps. I modified the GoogleMapFunctions.js file so that the scale is relocated above the searchbar:
case 'scale' : 
	var scalePos = new GControlPosition(G_ANCHOR_BOTTOM_LEFT, new GSize(5,37)); 
	map.addControl(new GScaleControl(),scalePos) ;
67.170.217.247 06:34, 4 July 2010 (UTC)Reply
Thanks for the suggestion again. I implemented it in this revision:
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68995 Jeroen De Dauw 13:53, 4 July 2010 (UTC)Reply

Map display problem in popup

[edit]

We recently upgraded from 0.5.5 to 0.6.3. Since the upgrade our link to display a popup of a map has been showing half a gray box and part of the map without the marker. Why was the “size:” option removed from the GMap2 constructor call? This appears to be causing the issue for us in these cases (per http://code.google.com/p/gmaps-api-issues/issues/detail?id=766).


Thanks, TWong 184.8.111.150 18:37, 29 June 2010 (UTC)Reply

Can you provide a link so I can have a look at the issue?
The size option in the JS is no longer needed, as the size is now auto-determined, to allow for dynamic sizes. Jeroen De Dauw 19:40, 29 June 2010 (UTC)Reply
You can see it happening with this page http://dev.openei.org/wiki/ABC_Solar,_Inc.
Click the Display map link.
Thanks,
TWong 184.8.111.150 22:23, 29 June 2010 (UTC)Reply
This is a better link to go to http://dev.openei.org/wiki/3TIER the display map link is in the box on the right side.
Thanks,
Twong 184.8.104.4 16:32, 30 June 2010 (UTC)Reply
It seems to be working perfectly here. What browser is the issue seen on? Jeroen De Dauw 11:47, 1 July 2010 (UTC)Reply
Apparently this occurs in IE, how typical >_>
It's just a style issue though, not a bug in Maps. Jeroen De Dauw 13:43, 1 July 2010 (UTC)Reply
Interesting you only see it in IE. I see the issue in Firefox 3.6.3, Chrome 5.0.375.86, and IE 8.0.6001.18928 on Vista. Another co-worker on a Mac is seeing it in Firefox and Chrome as well.
We came up with a simple fix for it which works for us with changes in Services/GoogleMaps/GoogleMapFunctions.js, Maps_GoogleMapsDispMap.php and Maps_GoogleMapsDispPoint.php. The diff shows the original code first to our code.
diff /opt/mediawiki/extensions/Maps/Services/GoogleMaps/GoogleMapFunctions.js GoogleMapFunctions.js
77,78c77,84
< //mapOptions.size = new GSize(mapOptions.width, mapOptions.height);
< return createGoogleMap(mapName, mapOptions, markers);
---
> if (mapOptions.width != null && mapOptions.height != null) {
> // Get just the numeric characters for width and height (excluding, for example, "px")
> var width = mapOptions.width.replace(/[^0-9]/g, );
> var height = mapOptions.height.replace(/[^0-9]/g, );
> mapOptions.size = new GSize(width, height);
> }
> return createGoogleMap(mapName, mapOptions, markers);
> return map;
99c105
< var map = new GMap2(mapElement, {mapTypes: mapOptions.types});
---
> var map = new GMap2(mapElement, {size: mapOptions.size, mapTypes: mapOptions.types});
diff /opt/mediawiki/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispMap.php Maps_GoogleMapsDispMap.php
87a88,89
> width: '$this->width',
> height: '$this->height'
diff /opt/mediawiki/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispPoint.php Maps_GoogleMapsDispPoint.php
90c90,92
< scrollWheelZoom: $this->autozoom
---
> scrollWheelZoom: $this->autozoom,
> width: '$this->width',
> height: '$this->height'
Thanks,
Twong 184.8.111.166 19:48, 1 July 2010 (UTC)Reply
So you are re-introducing the width and height parameters, and stripping out any % or px units in the JS? That's not going to be put in Maps, as it is a rather bad way to solve your issue. Jeroen De Dauw 14:40, 5 July 2010 (UTC)Reply
Hi Jeroen,
Can you give some guidance on what you would consider to be a good solution (and hopefully would accept back into the Maps codebase)? We would be happy to try to implement whatever you suggest and submit a patch.
Thanks,
Jamey Wood Woodjr 17:51, 6 July 2010 (UTC)Reply
I don't know how to fix this, and am not going to look at it, as it's a design issue. Someone skilled with css and related stuff should be able to fix it I guess. Jeroen De Dauw 21:05, 6 July 2010 (UTC)Reply

Error with Mapsize

[edit]

Hello, I'm testing the maps-/semantic maps extension for my wiki. I'm using MediaWiki 1.16.0beta3 and Maps 0.6.3. Always I set the size of a map I get this php-warning Parameter 1 to MapsMapper::isMapDimension() expected to be a reference, value given in /users/gewiki/www/extensions/Validator/Validator.class.php on line 547. The map gives an error-message: Die folgenden Fehler wurden in deiner Syntax gefunden: Der Wert x600 ist nicht gültig für Parameter width. Der Wert x300 ist nicht gültig für Parameter height.

I use the following code {{ #display_map: 51.5, 7.1 |width=600 |height=300 }}

Link for an example: http://gewiki.square7.ch/index.php?title=Test

Thanks for any hint. Wolfgang H. 08:52, 2 July 2010 (UTC)Reply

Can you try running the latest svn trunk code for both Maps and Validator (the version should say 0.6.4 a5) and see if you still encounter this issue? Someone already reported this, but I have never been able to reproduce the issue, so am unsure if it's currently fixed or not.
Note: if you don't know how to get the svn trunk code, just give me a poke and I'll do an export for you. Jeroen De Dauw 19:36, 2 July 2010 (UTC)Reply
I'm now running revison r68953 of maps and revision r68954 of validator and the problem remains. Wolfgang H. 17:46, 3 July 2010 (UTC)Reply
Annoying issue. I can not reproduce it anywhere and am unsure where it's coming from. Do you have any idea's? I will be releasing 0.6.4 soon, so it would be nice if this could be fixed by then. Jeroen De Dauw 19:14, 3 July 2010 (UTC)Reply
I thought it could be a problem of localization, because I use a german Mediawiki. But even if I switch wgLanguageCode $ = "de", to "en", the problem remains - only the error message change to english language.
Unfortunately I am not familiar with coding. But if you can give me suggestions to change something somewhere in the code, I'll try it out and tell you the result. Wolfgang H. 05:35, 4 July 2010 (UTC)Reply
I agree that it's not an i18n issue. It might be related to your php version, as I have not tested on php 5.3.x. I will do this soonsih though. You can try using an older version of Maps and Validator and see if that fixes the issue until it's actually resolved. 213.224.29.162 14:03, 4 July 2010 (UTC) 14:02, 4 July 2010 (UTC)Reply
I've tested with maps 0.5.5 and validator 0.2.2 and the problem with setting the size remains. Only the php-errormessage doesn't occur. Wolfgang H. 18:57, 4 July 2010 (UTC)Reply
Can you again try the most recent version from trunk? This would be Validator 0.3.4 a7 and Maps 0.6.4 a7. I suspect the php error is gone, but am having issue with my php 5.3 machine, so can't confirm. Jeroen De Dauw 20:46, 4 July 2010 (UTC)Reply
I'm now running the latest svn versions. The php error is not gone. There is still the warning Parameter 1 to MapsMapper::isMapDimension() expected to be a reference, value given in /users/gewiki/www/extensions/Validator/Validator.class.php on line 547. Also the problem with sizing the maps still remains unfortunately. Wolfgang H. 05:13, 5 July 2010 (UTC)Reply
You do not appear to be running the latest version at all, looking at http://gewiki.square7.ch/index.php?title=Spezial:Version
The php warning should actually be fixed, another person that had the same issue does not have it since 0.x.4 a7.
Most likely your width/height issue will be fixed once you get rid of the php warning, if it's not, remove your width/height limit setting in localsettings if you have set it. Jeroen De Dauw 14:19, 5 July 2010 (UTC)Reply
I newly tried to load up the last revision (69056), I could get from svn. If that isn't the latest version can you please mail me a zipfile of it, because nothing changed with the issue. I have no width/height limit settings in my localsettings. Thank you for your patience with me. Wolfgang H. 16:10, 5 July 2010 (UTC)Reply
You can download the code here Jeroen De Dauw 17:11, 5 July 2010 (UTC)Reply
With rc1 of 064 The problem is solved. Good work. Thank you for the solution to this annoying problem, and by the way thank you very much for this great MediaWiki extension. Wolfgang H. 17:29, 5 July 2010 (UTC)Reply

Map not showing

[edit]

Can you guys tell me why the maps doesnt load, but it works when I edit and save a page?

www.wikirio.com.br

Thanks... 201.54.232.138 00:00, 13 July 2010 (UTC)Reply

Can you provide a link to the failing map? Jeroen De Dauw 09:27, 13 July 2010 (UTC)Reply

Maps with Markers won't display

[edit]

Hi,

while trying to get Maps/Semantic Maps running, I encountered some strange problems.

Maps without markers typically render well, I did not yet manage to render any map with markers. In particular:

  • {{#display_map:New York City|service=openlayers}} works well, while
  • {{#display_point:New York City|service=openlayers}} produces an empty map (maximum zoom level, but nothing if you zoom in as well)

The problem exists for both services I tested (GoogleMaps and OpenLayers).

Similarly, the following Semantic Maps ASK-Query will produce an empty/"grey" map:

{{#ask: [[Kategorie:Person]]
| ?coordinates
| format=map
| center=New York
| forceshow=on
}}

Interestingly, if I remove/rename the coordinates property, the map renders with New York correctly centered. I then stepped into SM_MapPrinter.php and printed the $locations array, which seemed to work fine?!

Array
(
    [0] => Array
        (
            [0] => 49.0022222222
            [1] => 8.39222222222
            [2] => <a href="/wiki/index.php/Hans-J%C3%B6rg" title="Hans-Jörg">Hans-Jörg</a>
            [3] => 
            [4] => 
        )
...

The system is a private installation - so no public link (but I might give access to someone for investigation). The system configuration is as follows:

MediaWiki  	1.15.4
PHP 	5.2.11-pl0-udmedia (apache)
MySQL 	5.0.83-log
Semantic MediaWiki  (Version 1.5.1.1)
Maps  (Version 0.6.5 rc1)
Validator  (Version 0.3.5 rc1)
Semantic Maps (Version 0.6.5 rc1)
(plus a number of further extensions)

$wgLanguageCode = "de";

Any help / guidance for debugging/fixing that is appreciated... Hhappel 15:55, 26 July 2010 (UTC)Reply

Can you try running the latest trunk version of Maps? A bug has been fixed since rc1 that is probably causing your problems. After updating Maps you will need to refresh (action=purge) the pages with broken maps to make them working again. Jeroen De Dauw 18:05, 26 July 2010 (UTC)Reply
Indeed, updating Maps (only) did resolve the issue.
Thanks a lot for your quick reply and the terrific extension! Hhappel 08:47, 27 July 2010 (UTC)Reply

No Map Appearing

[edit]

MediaWiki 1.15.1, PHP 5.3.2-1ubuntu4.2 (apache2handler), MySQL 5.1.41-3ubuntu12.3, Semantic Bundle (Version 0.4.2.20100719). I am running localhost; I am designing the wiki for personal use. Maps and SMaps is 0.6.4. I am using Semantic Forms for this.

So, I am simply trying to add a field to display a map in the form; ideally, I would want to simply type the address into a geocoder (which would be in the form) to display it. Currently, when I enter the simple coordinates and preview I get only the coordinates (not a map) appearing in an amber/yellowish color. Additionally when I ran the test script it simply displays the coordinates in red.

Willing to give any info necessary; I appreciate your time! I don't know how to allow your machine to link to mine but am willing to do such if you tell me how (remote or whatever).

<noinclude> This is the "Yard Info" form. To create a page with this form, enter the page name below; if a page with that name already exists, you will be sent to a form to edit that page. {{#forminput:form=Yard Info}} </noinclude><includeonly> <div id="wikiPreview" style="display: none; padding-bottom: 25px; margin-bottom: 25px; border-bottom: 1px solid #AAAAAA;"></div> {{{for template|Yard Info}}} {| class="formtable" ! Yard ID: | {{{field|Yard ID|mandatory}}} |- ! Train Company: | {{{field|Train Company|mandatory}}} |- ! Reporting Mark: | {{{field|Reporting Mark|mandatory}}} |- ! City: | {{{field|City|mandatory}}} |- ! State: | {{{field|State|mandatory}}} |- ! Country: | {{{field|Country|mandatory}}} |- ! Address: | {{{field|Address}}} |- ! Jurisdiction: | {{{field|Jurisdiction}}} |- ! To/From Routes: | {{{field|To/From Routes}}} |- ! Resources: | {{{field|Resources}}} |- ! General Notes: | {{{field|General Notes|input type=textarea}}} |} {{{end template}}} '''Free text:''' {{{standard input|free text|rows=10}}} {{{standard input|summary}}} {{{standard input|minor edit}}} {{{standard input|watch}}} {{{standard input|save}}} {{{standard input|preview}}} {{{standard input|changes}}} {{{standard input|cancel}}} </includeonly>

<noinclude> This is the "Yard Info" template. It should be called in the following format: <pre> {{Yard Info |Yard ID= |Train Company= |Reporting Mark= |City= |State= |Country= |Address= |Jurisdiction= |To/From Routes= |Resources= |General Notes= }} </pre> Edit the page to see the template text. </noinclude><includeonly> {| class="wikitable" ! Yard ID | [[Yard ID Number::{{{Yard ID|}}}]] |- ! Train Company | [[Freight Company::{{{Train Company|}}}]] |- ! Reporting Mark | [[Reporting Mark::{{{Reporting Mark|}}}]] |- ! City | [[City::{{{City|}}}]] |- ! State | [[State::{{{State|}}}]] |- ! Country | [[Country::{{{Country|}}}]] |- ! Address | [[Geographic Coordinate::{{{Address|}}}]] **(My note 4 U This is on property: This is a property of type [[Has type::Geographic coordinate]].)** |- ! Jurisdiction | [[Jurisdiction::{{{Jurisdiction|}}}]] |- ! To/From Routes | [[To/From Routes::{{{To/From Routes|}}}]] |- ! Resources | [[Resources::{{{Resources|}}}]] |- ! General Notes | {{{General Notes|}}} |} [[Category:Yard Info]] </includeonly>

Should note that all extensions are added via the script in the Bundle. The Google API was placed where it called for it as well within Bundle.

Thanx! Vincit Omnia Veritas 15:48, 5 August 2010 (UTC)Reply

Have a look at the specific notes for 0.6 (and above) installation here. If your data structures are correct, I guess this is what the issue is caused by. Jeroen De Dauw 15:58, 5 August 2010 (UTC)Reply
So, I found the issue. I had to go into the Maps_Setting.php and add my API. Wanted to note here (for those like me who are novices) that when you add the API here (and the bundle area) that it now adds the deal where you can enter an address to be geocoded! :) Man, makes me really happy!
I never did figure out how to use forms to do the automatic entry of the map deal, so I simply grabbed your code and pasted it into a template and form and viola! So, by and large I'll use the automated deal on forms for simple forms and hard code the rest. In essence, the error occurred as I didn't know how to precisely run the stuff. Would be cool to get a DIY screencast or something for folks like me for the whole platform; maybe someone with a lot of time and experience will make one someday?! :)
Wanted to thank ya'll for creating the program as I think it is REALLY cool and I like it! I may have ?'s in the future; however, for now I am very content! Vincit Omnia Veritas 11:55, 16 August 2010 (UTC)Reply

Google Update

[edit]

It appears at there has been an update by Google today which means that maps aren't loading? They were working fine last night

My site is login access only so it's difficult to show an example.

All I get is a greyed out map with "Loading map..." which doesn't resolve.

The relevant details regarding my setup is as follows:

MediaWiki 1.16.0 PHP 5.2.13 (cgi) MySQL 4.1.22-standard-log

Maps (Version 0.6.5) Semantic Maps (Version 0.6.5)

Any ideas if there's going to be a patch or update?

Many thanks 94.10.194.32 (talk) 12:02, 17 August 2010 (UTC)Reply

This issue has resolved itself Graham E 13:55, 17 August 2010 (UTC)

Google Maps without the API

[edit]

Hey Jeroen,

I've been using Semantic Maps without issue for the past few months, however, I've noticed some strange behavior, especially now that I've tried to replicate it on another server.

During initial installation I inserted a Yahoo! Maps API to localsettings.php but not a Google Maps API, yet somehow I'm getting a Google Maps output. How is this possible? Is there a Google API hidden somewhere in the code? Furthermore, changing the mappingservice parameter doesn't affect the map, it's always Google! (though changing the default parser function works fine)

So, I eventually just accepted the first phenomenon, but now I have another problem. When I copied the application to a new server, Google suddenly complained about the API. This would normally make sense, but why does it care all of a sudden? Another strange thing is that Yahoo! is not complaining at all! It works fine with the same API. To make matters more interesting, when I view my wiki with the Opera browser, Google stops complaining and shows the map! What's going on??

I'm running: MW 1.15.1 ; SMW 1.5.1.1 ; Maps/Semantic Maps 0.6.5 ; Validator 0.3.5

Darryl 149.32.192.33 15:55, 29 September 2010 (UTC)Reply

Adding service=yahoomaps to a display_map/points call or format=yahoomaps in a SMW query should always result into you getting a Yahoo! Maps map. If you don't get one, you probably have some messed up configuration, but should still get a warning message stating you entered a wrong value for the mapping service parameter.
In any case, if you want all your maps to show up with Yahoo! Maps, add this code to the end of your LocalSettings.php file.
	$egMapsDefaultService = 'yahoomaps';
	
	$egMapsDefaultServices = array(
		'display_point' => 'yahoomaps',
		'display_map' => 'yahoomaps'
	);
Google Maps only demands an API key for certain types of installations. I noticed I can perfectly run it locally without any key. The Opera difference sounds like a cross-browser compatibility issue with the Maps JavaScript. Jeroen De Dauw 04:05, 30 September 2010 (UTC)Reply

Map does not appear with Special:Call extension

[edit]

I am testing with the Call extension. It works well if I disabled the map in the template (the address was geocoded and the query returns correct results), but if I try to show the data on the map it doesn't work. (example) 67.170.217.247 02:24, 3 October 2010 (UTC)Reply

The map is not working because MediaWiki requires a different way of adding JavaScript on special pages then in articles. So I'm afraid you simply can't do that for now. Jeroen De Dauw 06:10, 3 October 2010 (UTC)Reply
That's probably why the Special:Ask page doesn't show the maps either, even though there's a very nice form for maps. 67.170.217.247 01:07, 4 October 2010 (UTC)Reply
Maps on Special:Ask are working fine in the latest release. The next version of Maps (0.7) should solve the problem you are having with the Call extension. Jeroen De Dauw 08:38, 5 October 2010 (UTC)Reply

Google Api warning adressing pages from localhost

[edit]

Hi If we are offline (no internet) we test our application using "localhost" In this case we receive the Google Api key warning. We know we are offline and we know non map will be displayed but is there a way to disable the Google warning ?

Regards Solab 77.58.252.132 22:13, 5 October 2010 (UTC)Reply

Simply display maps with another mapping service, such as openlayers. You can change the global default using the $egMapsDefaultService setting. Jeroen De Dauw 08:13, 6 October 2010 (UTC)Reply

Beta problem

[edit]

I tried to install the 0.7 beta version and I got this error message:

Warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback,
'MapsCoordinates::staticMagic' was given in /home/xxxxx/transitunlimited.org/includes/Hooks.php on line 133 67.170.217.247 09:49, 7 October 2010 (UTC)Reply
I'm guessing you tried to install beta 1, which has such an issue on some installs. Can you try beta 2 (which I put online a few hours back), or better yet just update from svn (one issue has been fixed since beta 2). Jeroen De Dauw 19:01, 7 October 2010 (UTC)Reply
I tried the beta 2 and I got this when I tried to open up a #geocode or #display_point page:
Fatal error: func_get_args(): Can't be used as a function parameter in
/home/xxxxx/transitunlimited.org/extensions/Validator/includes/ParserHook.php on line 374
The map displays fine if used #ask. 67.170.217.247 08:49, 8 October 2010 (UTC)Reply
That would be the issue that got fixed after beta 2. I'll upload another version later today. Jeroen De Dauw 10:53, 8 October 2010 (UTC)Reply
Beta 3 is ready and should fix this issue. get it. Jeroen De Dauw 17:45, 8 October 2010 (UTC)Reply
There are some problems:
  1. The controls parameter doesn't seem to work. The search box doesn't show and you can't select between maps and satellite.
  2. The regular maps are showing this error message: Warning: There is an error in your syntax.
  3. With the current version, I can nest #geocode with #ask so I can find locations within a certain distance. The new version allows me to do either #geocode or #ask, but not both.
  4. The centre parameter doesn't seem to work. 67.170.217.247 21:17, 8 October 2010 (UTC)Reply
I cannot reproduce 1 and 4. I'm guessing you made an actual syntax error in your test, which then also caused 2. Although I'd expect the actual error to also be shown. Can you reproduce this behaviour on the docs wiki, which is currently running beta 3?
I'll check up on point 3 - didn't test any nesting yet. Jeroen De Dauw 17:37, 9 October 2010 (UTC)Reply
I guess the point 4 is OK. I found the problem with point 1 is that I tend to put a space between the comma and the next parameter, which results in error message in the beta version (older version works fine). If I take away that space, everything works fine.
{{
#display_point:37.48446, -122.2362
|width=600
|height=300
|controls=small,type,scale,searchbar
}}
{{
#display_point:37.48446, -122.2362
|width=600
|height=300
|controls=small, type, scale, searchbar
}}
67.170.217.247 20:02, 9 October 2010 (UTC)Reply
Oh - good find :)
I'll fix this for the upcoming RC. Please continue any beta feedback here. Jeroen De Dauw 22:32, 9 October 2010 (UTC)Reply