Last modified: 2007-11-02 19:38:02 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T13679, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 11679 - Geographic coordinate requires degree symbol, other compact format issues
Geographic coordinate requires degree symbol, other compact format issues
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Markus Krötzsch
http://ontoworld.org/wiki/Geographic_...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-10-16 09:49 UTC by S Page
Modified: 2007-11-02 19:38 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description S Page 2007-10-16 09:49:47 UTC
User on semediawiki-devel complained that [[coordinates::38.926832, -77.03201]] for Washington, DC doesn't work.

This isn't a regression from 0.7, but it would be nice to support a more compact format. Formats like http://geotags.com/geo/geotags2.html use this:
  <META NAME="geo.position" CONTENT="49.2;-123.4"> 

The code works by splitting on °|SMW_GEO_MIN|SMW_GEO_SEC|N|E|W|S 
in this case there's no split and the entire string is in $curnum.  This is hard to fix because comma might be a decimal point separator, but perhaps you could special case a check for /number,number/.

Arguably the code should report an error at  "// unprocessed chunk, error" if it hasn't accumulated a latitude.

Also, [[coordinates::32.715N 117.163W]] doesn't work, again the degree symbol is required.  In this case the code fails because no angle has accumulated, but $curnum holds the decimal value.

For now http://ontoworld.org/wiki/Type:Geographic_coordinate describes all the working coordinate formats.
Comment 1 Markus Krötzsch 2007-10-18 13:42:23 UTC
Thanks for the analysis. I also came across the decimal seperator issue. We will see what we can do.
Comment 2 Markus Krötzsch 2007-11-02 19:38:02 UTC
I think all of the above work now. Some more tests might be in order.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links