Template talk:GeoTemplate/Archive 5

Latest comment: 16 years ago by Zyxw in topic MSN link spam
Archive 1 Archive 3 Archive 4 Archive 5 Archive 6 Archive 7 Archive 10

Geographical Survey Institute Link does not work well

Google Japan link for ja:大畑駅 works well. But Geographical Survey Institute Link for that place does not work well. Perhaps something wrong happens. Please check. Thank you. Penpen0216 05:26, 8 July 2007 (UTC)

The problem is caused by the fact that Geographical Survey Institute direct link URL does not have a separator between degree/minute/second. So when the minute or second has only 1 digit, the link messes up.
Current URL : http://watchizu.gsi.go.jp/watchizu.aspx?b=32953.75&l=1304715.8&r=1
Intended URL: http://watchizu.gsi.go.jp/watchizu.aspx?b=320953.75&l=1304715.8&r=1
The above lines demonstrate the problem. I tried to fix it with magic word "padleft", but it didn't work. Someone one else with better knowledge of this template or wiki code would have to fix it.--Voidvector 08:08, 8 July 2007 (UTC)
I didn't understand at first what the 0 was doing in the middle, but I now figured out that the service expects degrees, minutes and seconds concatenated together without any separators. Padleft didn't work because the coordinate variables aren't generated and filled in by MediaWiki, but by GeoHack, and so they're not available to MediaWiki functions. This needs a GeoHack fix indeed, to add left zero padded variables of two and three digits, or some multiuse variable where the necessary padding is given following some syntax. What would be understandable for GeoTemplate editors? --Para 18:35, 1 August 2007 (UTC)
If new minutes and seconds variables are introduced, i.e. creating 2 different variables for the same thing, some people might freak out and not know which one to use. I think multiuse version (e.g. a padleft function) would be nice. This way they are kept separated. --Voidvector 19:07, 1 August 2007 (UTC)
Would it be a problem if we padded all seconds and minutes variables so that their value would go from 00-60?
I don't think that would look too good and it might break some services. It wouldn't be consistent either, unless degrees were displayed padded as well, where the ±180 limit would force 1° shown as 001°. I agree with Voidvector that new separate variables would add unnecessary confusion. How about allowing sprintf format strings at the end of parameter names, like {latmindec,%02d} ? That would again make it more complicated than simple search&replace though. --Para 00:33, 2 August 2007 (UTC)

Navbar

I added a makeshift navbar to help rectify the need to scroll a long TOC. It would be great if someone could prettify it. Andy Mabbett 16:10, 12 July 2007 (UTC)

I think we should remove the __TOC__. What do you guys think? --Steinninn 13:54, 13 July 2007 (UTC)
I've switched to a limited-depth TOC (after first re-arranging the sub-sections). If people like that, rather than the previous, longer, version, the navbar (currently commented-out) can go. Andy Mabbett 14:57, 13 July 2007 (UTC)
I liked it better when it was a horizontal TOC. But then again, people are much more familiar with the vertical one. --Steinninn 17:22, 13 July 2007 (UTC)

Geolinks:Cityscale

I have managed to find a way to get the Geolinks:Cityscale template to pass the name of the location to this page as the final parameter. How can this now be used as a title param for the third party links? --Scotthatton 17:47, 12 July 2007 (UTC)

Sites without coordinates links

The previous split between sites with direct links and those that don't use coordinates made it easier to identify the first group. The advantage of having a section with sites that don't provide such links was that it avoided everybody else to figure out why they are not listed in the main section. Personally, I'd prefer to restore the separate section for those links or comment out any site that doesn't provide coordinate based links. -- User:Docu

Such links are currently in sparate sections anyway, but perhaps Docu (talk · contribs) could explain how that could be done while still providing a TOC, like that currently in use, which reduces the need for scrolling? Andy Mabbett 08:49, 14 July 2007 (UTC)

Shaded Relief

I found a great site with world wide rleif mapping alongwith google and live maps. Can someone try to add http://www.shaded-relief.com/ to the list -- PlaneMad|YakYak 06:00, 14 July 2007 (UTC)

I can't seem to see any way to pass coordinates to it. Andy Mabbett 08:37, 14 July 2007 (UTC)
e.g. http://www.shaded-relief.com/?lat=30.0571&lng=31.2272&z=8&t=1&q=Cairo
lat : Latitude
lng : Longitude
z : Zoom
t : Type (0=Map, 1=Satellite, 2=Hybrid, 3=Relief, 4=Relief+, 5=Natural, 6=Natural+, 7=VE)
q : SearchQuery
Cush 17:31, 16 October 2007 (UTC)

Template:GeoTemplate/Lang

This template is not perfect. I have not been able to figure out how to include type and region. --Steinninn 20:42, 14 July 2007 (UTC)

What are its perceived advantages, over putting the interwiki links in the left hand column, where people will expect to find them, as on most other pages? Andy Mabbett | Talk to Andy Mabbett 09:36, 15 July 2007 (UTC)
The Geohack script doesn't support left column interwiki links. If you look at the current Wikipedia page, it has a few interwiki links on the side, but if you look at this page, the links aren't there. --Voidvector 12:34, 15 July 2007 (UTC)
Voidvector is right. This works similar to commons interwiki links. --Steinninn 17:04, 15 July 2007 (UTC)
Thanks for the explanation. I'm still unclear about the relationship between this template and the GeoHack page, despite having asked for clarification previously. Andy Mabbett | Talk to Andy Mabbett 21:10, 15 July 2007 (UTC)
To me, it is unclear what you do not understand. The normal interwiki link the templates together. These new interwiki's link the toys together. These are two different things. I think it's just as important to be able to jump from one language to the other while using the toy as it is in the template. --Steinninn 01:57, 16 July 2007 (UTC)
My latter request for clarification has nothing to do with interwikis. Andy Mabbett | Talk to Andy Mabbett 10:15, 16 July 2007 (UTC)
If you know how to put these links on the left hand column, them tell me. But my letter has still not been answered. How can we include type and region in the links? --Steinninn 11:52, 16 July 2007 (UTC)
The connection between this template "GeoTemplate" and the php script "GeoHack" is that every time GeoHack is used (i.e. someone click on a link to GeoHack), GeoHack reads a copy of GeoTemplate, and replace the {tags} with results of calculation. The reason we store the content in GeoTemplate is that it retrains the everybody-edits feature of a wiki, while GeoHack perform the actual calculation and page creation (the kind wiki can't do). --Voidvector 18:50, 16 July 2007 (UTC)

MSN link spam

Seems to me there are a few of people who like to add MSN links to every region there is. Sounds very much like link spam to me. --Voidvector 02:49, 19 July 2007 (UTC)

The reason for those multiple links is because the URL for MSN Maps uses different region codes. The link provided under the Global systems heading uses the World Atlas (2) region, which does not give display the more detailed maps that are available for locations in North America (0), Europe (1), Australia/New Zealand (3) and Brazil (4). Further details can be found below under the heading #MSN Maps links and region codes. -- Zyxw (talk) 20:46, 28 December 2007 (UTC)

Language template

I recently moved the "language" template to the end of the page, under "see also", as it was moving more important content "below the fold" on smaller screens, and will only be used by a small percentage of this page's visitors. I indicated what I had done in my edit summery. My edit was quickly reverted, with no edit summary, in an edit marked as "minor"; I find such deceptive unacceptable. Andy Mabbett | Talk to Andy Mabbett 10:16, 22 July 2007 (UTC)

I do agree that the revert was unnecesary. But I don't agree that the tamplate should be at the bottom. At Wikimedia Commons these kinds of themplates are at the top. And I think, when we get more language links we will eventually have more then 50% of the visitors that find these links usefull. And I don't believe that we get more links by having it at the bottom. Recently we got 2 links in 4 days. I suspect that number to fall fast if we move the template. --Steinninn 11:38, 22 July 2007 (UTC)
Maybe we should make the template smaller. But if we start that, we should also remember to do the same edit on the other 9 templates on the other wikipedia sites. --Steinninn 11:52, 22 July 2007 (UTC)
Smaller would indeed be better. A specific section with those links should do. Users on wikipedias in other languages where a specific page is available are (or should already be) directed to the specific pages. -- User:Docu

How about improving GeoHack to read standard interwiki information from the GeoTemplate page, or parse some language template if absolutely necessary, and then display the links the same way Monobook does? There is plenty of empty space in the traditional Monobook interwiki link box location in GeoHack, after all. --Para 20:51, 22 July 2007 (UTC)

Para's idea is a much better solution then the current one. If anyone could find a way to do that. I tried contacting Egil for some help, but aparently he's busy in real life. I don't know how to write stuff like this, so we are going to have to find one that dose. --Steinninn 16:21, 23 July 2007 (UTC)
You can also try contact User:Magnus Manske, he hosts the current version of the GeoHack. If we can get him or any of the developers to participate on this discussion page it would be great, because there are a number of problems with the current system right now.
  1. The current system cannot produce digits with zero padding. This is required for at least 1 link I know.
  2. The current system doesn't populate some variables such as type and region, even though it uses them as part of its calculation.
  3. Some users wants to be able to pass names to the mapping website. Some websites can use this for better pinpointing or labeling.
--Voidvector 10:47, 24 July 2007 (UTC)
I added a new topic below to talk of modifications that require not just a GeoTemplate modification, but modifications to the GeoHack php: #GeoHack improvements. The last two of your items are already mentioned, but I'm not sure how the first is a problem. --Para 09:52, 26 July 2007 (UTC)
The first problem actually arose from Template_talk:GeoTemplate#Geographical_Survey_Institute_Link_does_not_work_well above. --Voidvector 16:25, 1 August 2007 (UTC)

Coor templates

As {{coor at dm}} and {{coor at dms}} are templates suggested to use on wikipedia, there isn't really a reason not to include them or even to remove them ([1], [2]). I took the liberty to add them back. --User:Docu

(Previous comment by Docu (talk · contribs)) The reason for removing them is that they don't do anything which {{coord}} (which also "suggested for use on Wikipedia - and what a redundant phrase that is!) does not do; but lack the latter's additional functionality, including offering the viewer a choice of display format, and including a Geo microformat (this has been explained to you before, more than once). There is no good reason to include them alongside coord; to do so simply bloats the page, and is likely to confuse readers and editors by offering superfluous choices. They should be removed. Andy Mabbett | Talk to Andy Mabbett 16:35, 22 July 2007 (UTC)
(Previous comment by Pigsonthewing (talk · contribs)): why remove the user's choice of templates? To simplify viewing, you may want to move the {{coord}} ones to a subpage. -- User:Docu
The user has the same choice of templates as before; it's simply redundant to offer that choice here, for the reasons given above. Your unhelpful comment about moving the cord examples appears to be part of your ongoing and bizarre campaign against the use of that template, for reason - if any - you have yet to make clear. Andy Mabbett | Talk to Andy Mabbett 16:51, 22 July 2007 (UTC)
(Previous comment by Pigsonthewing (talk · contribs)): If you remove it, there is no choice. BTW isn't there an error in the way coord was added? -- User:Docu
I'm not here to play your games.Andy Mabbett | Talk to Andy Mabbett 16:55, 22 July 2007 (UTC)
(Previous comment by Pigsonthewing (talk · contribs)): I don't understand your comment, but thank you for fixing your addition of coord [3] anyways. Looks like it needed some serious fixes. -- User:Docu

How is wiki markup information useful on a page linking to sources outside Wikipedia? In my opinion they should all be removed. --Para 20:53, 22 July 2007 (UTC)

There are some wikis that use them as input! -- User:Docu
Various coordinate templates are used in wikis for coordinate entry, yes, but GeoTemplate should be used only after someone clicks a link produced by the coordinate entry templates. What use is there to display some possible wikitext entry formats after the data has already been entered and is being used through GeoHack? If someone wants to see how coordinates can be entered, they should go to the article they came from, or a manual of style or a project page related to coordinates. There should be nothing parsing GeoHack's output in mass, that'd be misuse of resources. --Para 17:41, 23 July 2007 (UTC)
"misuse of resources" - can you provide a citation for that claim, or did you make it up? Andy Mabbett | Talk to Andy Mabbett 19:59, 23 July 2007 (UTC)
Are we talking about the same thing? I would have thought it to be obvious that automated requests to a php script that fetches a rarely changing Wikipedia page on every request just to fill in a template that anyone could do locally is a waste of resources. Is that actually being done somewhere as input to a wiki?? There must be some misunderstanding here, where is it? --Para 20:17, 23 July 2007 (UTC)
So, no citation then; "misuse" is just your personal spin. Andy Mabbett | Talk to Andy Mabbett 22:27, 23 July 2007 (UTC)
Geolinks can be called from any language. It happens that I find coordinates on an article in another language. There is nothing automated about this. Anyways, I think we get carried away. Special:Cite offers all kinds of formats without problems. -- User:Docu
That's a viable use case indeed, thank you for explaining what Andy failed to do. Do you often find yourself copying coordinates from another wiki? If so, there's work for an interwiki bot to copy coordinates back and forth between Wikipedias in different languages. Have any such bots been run lately? --Para 07:29, 24 July 2007 (UTC)

Redesign?

I've always found this map hack along with the ISBN page to be horribly confusing. It is cluttered up with unnecessary link. Does not provide an easy visual way of determining of what each of the services have available. And the discussion and edit links are the wrong place.

The page should be similar to a disambiguation page, providing only the link where the user wants to go. Should have a tablish layout (possibly similar to another map hack [4]). And barrow more the interface elements from Wikipedia, possibly even the sidebar to put links that don't fit on the page. —Dispenser 03:27, 25 July 2007 (UTC)

It's alarming that another map link service has been forked. Our GeoTemplate is obviously not serving people well enough, so redesign is a good idea. The Dutch site is indeed more clear, but I think such a table wastes too much space with the map, satellite and hybrid links presented in that way. Here's some ideas I've thought of that might make the page more usable:
  • Currently the coordinates and scale appear as the first thing on the page, with a huge 140% font, taking half the screen space already. Since most people come to GeoHack for the links, the coordinates could be put in a little box in the corner of the page.
  • Something shorter to replace the "Find this location", icon(s) maybe?
  • Icons for map, satellite and hybrid links. Perhaps also icons for the services themselves? All of them would of course need alternative texts, or more.
  • Use a template to enter the links to have them all consistent. Elements could be the name wikilinked or not, type, link, icon, notes. Currently there seems to also be a link to each service's original description page.
There's also work in progress to add functionality to GeoHack to place the relevant sections first together with the global one, depending on the coordinates in the request. For that the design of the sections would have to be narrow enough so that two columns of links could be fit in one screen. What else could be improved? --Para 11:53, 25 July 2007 (UTC)
The coordinates are to big, I agree, but they should still be clearly visable, not just in the corner. I think an icon for a link is not a such a good idea, people are used to the idea of images being links to the images page, not an external link. A redesign is clearly needed. --Steinninn 17:08, 25 July 2007 (UTC)
If there is to be a redesign, I'd like to see accessibility considerations taken into account; not least the use of unique linking text. Andy Mabbett | Talk to Andy Mabbett 14:21, 25 July 2007 (UTC)

I've download Magnus' and created a sandbox template, you can check out the output to see how it looks. —Dispenser 21:59, 25 July 2007 (UTC)

To me there doesn't seem to be much difference from this sandbox template and the original, mostly that you have taken out a lot of other useful links. I do like the table, maybe we should do that with all the links. --Steinninn 22:13, 25 July 2007 (UTC)
I was trying to applying disambiguation pages standard which states the page is to help people find the information they want quickly and easily. Anyway your feel to edit it how you see fit. —Dispenser 22:37, 25 July 2007 (UTC)
Sorry I miss-interrupting you, I should have mention that I only included a small subset to make editing easier. —Dispenser 22:43, 25 July 2007 (UTC)
Good work, now everyone can set up their own proposition for how a section could be redesigned, without having to mess with this "production" template yet. Hopefully you will be ready to play with the underlying code as well and quick to apply patches, as Voidvector had some propositions above and there are other changes in the works too. --Para 22:40, 25 July 2007 (UTC)
First off, I don't know php, but I manage to hack in (with a ugly hack) the language sidebar. I've also added 'q' parameter to be passed along into the text. So it should at least be possible to experiment with some things. —Dispenser 02:29, 26 July 2007 (UTC)

Templated table with icons

I liked the templated table with icons but the logo's might be copyright violations. I love the language sidebar! --Steinninn 00:26, 28 July 2007 (UTC)

As nice as they look they're horrible for accessibility reason (see {{ClickA}} documentation) and as a another noted users may expect the link to take them to the image page. I may be able to hack something in the post processor, but it would increase the learning curve—Dispenser 20:59, 28 July 2007 (UTC)
Since it's kind of out of the Wikipedia part (the wikipedia logo isn't there as well as other things) I'm guessing that most people will stop thinking about Wiki elements and see it as a "normal webpage" where images are usually useful links. Especially when there are a lot of these images. --Steinninn 01:13, 29 July 2007 (UTC)
Another thing, it would be nicer that the php would recognize the regular interwiki links and change them into our interwiki links. --Steinninn 01:23, 29 July 2007 (UTC)
Agreed, this was proposed below. --Para 23:55, 30 July 2007 (UTC)
The Click template generates some ugly html indeed, but that's just an ugly workaround for a proof of concept that MediaWiki won't allow by simpler means. Otherwise I don't see accessibility issues with the map/satellite/hybrid icons. How could an icon image and a map link be tagged so that post processing can combine them to a simple <a><img></a> set? The GeoTemplate page doesn't have to look exactly the same as it does after GeoHack, but it does have to stay editable without too many requirements, while still being valid with the post processing for all Wikipedias. How about requiring to use a template for the whole table or other structure, or to give more design freedom, use a template for a single service type (something like {{satellitelink|url=foo}}), where the template must provide the icon image and the link wrapped in a span element with an appropriate class, so that the contents can be combined? Or would having GeoHack modify the page in such a way be too non-wiki, since the current post processing of the page content is simple search and replace only, and we should just use the output MediaWiki has to offer?
On the issue of the service provider icons; I don't like them either, they take too much attention, don't help in making the page look consistent and don't really serve as identification which is what I originally intended them for. The whole Info column is a bit unfinished: I couldn't think of any good symbol or text other than the name of the service to use to link to the wiki article or the service's own description page, so I ended up using the inappropriate question mark. It doesn't give much hint on what the link leads to. I think the name of the service in the first column should not link anywhere as it used to serve the "Map" link function earlier, and is ambiguous anyway. Superscript links might be good, though to make them understandable they'd have to be fairly long. Also, the Notes column is a big waste of space and I don't think much of the text in the current GeoTemplate is too useful, as users really need to check each service themselves to see if they're of any use. Are there more ways we could use to describe the services other than free form text? Anyhow, to summarise, I think the Info and Notes columns should be dropped from the proposition. That would make the sections quite narrow and allow two to be floated side by side on most screens. --Para 23:55, 30 July 2007 (UTC)
Dispenser changed the link icons to be displayed through CSS, so that people without CSS see text links. This requires no magic post processing or invisible hints, I like it! To not add more work for GeoHack's maintainer, could the styles be added to MediaWiki:Common.css or should a MediaWiki:GeoTemplate.css be created? --Para 16:56, 31 July 2007 (UTC)
I've created {{GeoTemplate/sandbox/main.css}} for now, we may need to to MediaWiki namespace if full protection is desired or we could semi-protect it.

Redesign sub-section 1

As it stands now, I'm also concerned that accessibility seems to have been disregarded, rather than improved. There are empty alt attributes, no accessible table mark-up, I realise that some of these issues may be symptoms of problems with Wiki mark-up, but there must be at least some work-arounds that could be included. I suggest running an improved version of the proposed design(s) past some accessibility exerts, perhaps at http://www.accessifyforum.com/ Andy Mabbett | Talk to Andy Mabbett 20:11, 30 July 2007 (UTC)

What is accessible table mark-up? --Para 23:55, 30 July 2007 (UTC)
accessible table mark-up. Also, please don't move my comments under misleading sub-headings. Andy Mabbett | Talk to Andy Mabbett 11:23, 31 July 2007 (UTC)
I'm not sure what you're after. It seems you're commenting that the tables generated by MediaWiki aren't accessible enough. It would make no sense to fix that in GeoHack, as such a change should affect all Wikipedia tables. Icons however, which generally aren't used in Wikipedia with accessible markup, could be implemented with a workaround in GeoHack. --Para 11:49, 31 July 2007 (UTC)
Which is why I wrote: "I realise that some of these issues may be symptoms of problems with Wiki mark-up, but there must be at least some work-arounds that could be included. " Andy Mabbett | Talk to Andy Mabbett 13:44, 31 July 2007 (UTC)
Andy are you using a validation service or are you looking through the source its self since there are thing the service doesn't change (1:30000 is spoken as 1 colon 30000 instead of 1 to 30000, at least in Opera). I fixed the markup so it almost validates as XHTML strict (stupid lang box hack). Its been passing the lynx test for sometime now. Perhaps you could design a layout to add to the list, I'm really interested in seeming some other design. —Dispenser 18:07, 31 July 2007 (UTC)
Accessibility != validation. You could fix "1:30000" with an abbr element, were such allowed. Andy Mabbett | Talk to Andy Mabbett 13:48, 1 August 2007 (UTC)

Rules/Guidelines on links

I believe it would be wise to have stated/remind somewhere of what links are allowed. Here are my suggestions:

  • External links should take the reader to a place with information relevant to that location. [5]
  • Editors should not be hesitant to remove dead links, as they provide no value.
  • Use few link as possible. Preferably designed like a disambiguation page.
  • Also there is no reason why we need to include pages to the front page of the site.
Agreed, but we should link to an information page about the service if one exists, for details about supported url parameters and such. --Para 08:24, 14 August 2007 (UTC)

We should probably also include a few exerts from the official linking policy. —Dispenser 16:55, 11 August 2007 (UTC)

I could only think of one more:

  • Service names shouldn't link anywhere because it's not obvious where the link leads (place with information relevant to the location, wiki article, service info page). --Para 08:24, 14 August 2007 (UTC)

Can we have openstreetmap.org linked in the table there? This page can feed through lat/long/zoom information to an openstreetmap URL such as http://www.openstreetmap.org/?mlat=51.52753&mlon=-0.080499&zoom=14 -- Harry Wood 13:58, 10 September 2007 (UTC)

Redesign and WikiMiniAtlas

I propose that the redesigned geohack page include an embedded (non-popup) WikiMiniAtlas viewport with the redesigned data below. Our own mapping service should take precedence, even though alternative sites provide value to the readers as well. --Gmaxwell 17:27, 16 August 2007 (UTC)

That seems reasonable, but how large (in pixels and file size) would it be? And what would users with no Javascript see? Andy Mabbett | Talk to Andy Mabbett 18:30, 16 August 2007 (UTC)
Hopefully the non-javascript users will see a collapsed div. And could the box be made resizeable like the way safari does textareas in the 3.x version and remember it (via cookies) for the next time? Also, should I import a /geohack.js in my version? —Dispenser 23:05, 16 August 2007 (UTC)
  Done, I hacked something in, it can't be resizeable since the URL requires a viewport size. Maybe this should be filed as a bug with the wikiminiatlas people? —Dispenser 00:53, 19 August 2007 (UTC)
the wikiminiatlas people, that would be me :-). After some server-side optimizations this will be my top priority. In fact the only thing keeping this from working is the fact that setting initial zoomlevel does not work yet. --Dschwen 12:51, 22 August 2007 (UTC)

GeoHack improvements

To go together with the GeoTemplate redesign, GeoHack could use some changes too so it's best to talk them through. Feel free to add comments in between.

  • Interwiki sidebar. To keep everything as much wiki-like as possible, the interwiki links in GeoTemplate should be given as anywhere else in Wikipedia, without using any special templates or having to specify each and every possibly useful parameter. GeoHack retrieves the MediaWiki parsed html containing the interwikis in the p-lang element, where the languages and codes can easily be extracted, and a similar interwiki box created using the parameter line from the original unparsed request with only the language= parameter changed. --Para 09:52, 26 July 2007 (UTC)
There seems to be some efforts to reinvent the wheel with Template:GeoTemplate/Lang and Template:GeoTemplate/Lang/sandbox. This looks very complicated and pointless really, since MediaWiki already provides a fine interwiki box created from the interwiki markup everyone knows. Why not use it? All GeoHack has to do is take the p-lang element of the GeoTemplate page, iterate through every list item and change the link from "http://(\w+).wikipedia.org/.*" to "http://tools.wikimedia.de$_SERVER['REQUEST_URI']&lang=$lang", where $lang was captured from the interwiki list item. Then just place the box where it belongs, and all language names, ids and parameters generated by MediaWiki will be retained as such without creating any magic templates with odd markup. Simple, easy. Yea? --Para 22:12, 31 July 2007 (UTC)
I was being bold. I thought it was a good idea that the template recognizes in what language it's working in to make it bold (or not include it at all). If you know how to improve it even more with the suggestion, Be bold --Steinninn 22:37, 31 July 2007 (UTC)
It was easier said then done, at least for me. I ended up replacing parts of the URL since regex seem to be too CPU hungry for this script. But on the upside you can now specify the page to parse. —Dispenser 00:17, 1 August 2007 (UTC)
  Done Works perfectly, thanks! The code can always be prettified later when all these features are combined to the "production" GeoHack (for example by using request_uri or query_string with &language replaced, instead of using {params}, to support any current and future url parameter such as &title). --Para 06:58, 1 August 2007 (UTC)
Could a diff of this feature be prepared as soon as possible for patching GeoHack proper? People seem to be working on other Wikipedias to start using the workaround template, and it's all for nothing really. --Para 19:46, 2 August 2007 (UTC)
My code should be available from the page its self [6]. The main changes are on the lines containing $template and $langbar, but I'm not sure if it'll be easy to merge with the main one since I changed the structure of the page to better match the output of mediaWiki. —Dispenser 22:32, 2 August 2007 (UTC)
  • GeoTemplate sections. There's work in progress for GeoHack to be able to move the sections related to the requested coordinates to the top of the page automatically depending on country border polygons. For that the sections would need to be named in a predictable manner in all languages. Since MediaWiki doesn't seem to allow creating html anchors other than with the =heading= syntax, I suggest that we name all the sections as ===ISO country code=== to have predictable html anchors, and modify GeoHack to translate the codes of the headings into country names using the language requested, while still preserving the anchors. The names can be their default translations (defined in ...?), or in case something needs to be different, translated using a Wikipedian created translation table on each of the GeoTemplate pages. This may lead into problems with busy small areas that use a "local" map service of a bigger area, or with small areas that don't have their own country code but have good map services for that small area only. It would only a problem with sections that span over the length of a single screen, though. If we were building the html from scratch and thought of ease of coding, it would of course be good to have div elements with the ISO ids, but that would require special markup on the GeoTemplate page, and for ease of editing I think we should keep it as close to other wiki pages as possible and use the standard heading markup which is then only extended by GeoHack. --Para 09:52, 26 July 2007 (UTC)
Take a look at {{anchor}}. And wouldn't it be more preferable to to give each of the services a coordinate and range in which they're valid? Then we could sort them by proximity. —Dispenser 16:46, 26 July 2007 (UTC)
It might be if countries were defined as a centre point and radius, but unfortunately they are more complicated than that. Using predefined border data solves the problem. You have some point there though, as not all "global" services are useful everywhere. We would need some way to score them, not on people's preferences but depending on the service's quality at each of the local sections. I haven't figured out a way to format that in an editable way.
For the anchor thing, an identifier like that could be placed in a templated design, like to the one I just wrote in the sandbox. There may be some concerns doing that though, as it's be best to have the GeoTemplate page as requirement-free as possible so people can easily edit it, especially when the translated pages drift further away from the English Wikipedia. If we rely on something else than section names (or codes) as used everywhere else on wiki, all GeoTemplate editors will have to remember to include the required elements, which may not even be visible in preview so they won't notice anything wrong if something is forgotten. The choice of section formatting will have to take this into account, in addition to the eventual GeoHack implementation of the moving, which will probably rely on an identifier of some level, and move everything from that point until the next identifier of the same level. --Para 11:56, 27 July 2007 (UTC)
  Done See http://lists.wikimedia.org/pipermail/wikipedia-l/2007-October/030214.html. --Para 21:28, 12 October 2007 (UTC)
  • Coordinate title. Some map services support a name for the requested location, which can be shown as the title of the page or on the map with the placemark. I can think of two ways to have automatic titles:
    • Wikipedia could provide a title to GeoHack with &title={{PAGENAME}} added to {{Coor URL}} (which is what all coordinate templates use to link to GeoHack). Most coordinates here could be named this way after the article, but some articles contain inline coordinates as well that point to a smaller location within the article's main area, or to a related location. In that case it would be a problem if all uses of coordinates automatically gave the name of the page as the title, unless GeoHack was modified to override the &title= if a _title: paremeter has been specified. Alternatively, we could just define &title as the title of the page the user came from since http referer is not reliable, and leave it at that. --Para 09:52, 26 July 2007 (UTC)
  Done in Template:Coor URL. --Para 21:28, 12 October 2007 (UTC)
    • The coordinate templates could be modified to add the pagename when the coordinates are to be shown at the top of the page. For inline coordinates there is a proposal for coord to be modified to take a name parameter, originally thought for microformat use, but as an identifier the value might as well be used for &title too. Then (with confusing naming), coordinates that go to the article's title would automatically be &title={{PAGENAME}}, and inline coordinates &title={{{name}}} if a name has been given. Personally I think this is the cleanest solution. --Para 09:52, 26 July 2007 (UTC)
  Done See Template:Coord#Usage. --Para 21:28, 12 October 2007 (UTC)
  • Uses the significance of the figures (sigfigs) of the coordinates to determine the appropriate scale if the scale is not otherwise defined. —Dispenser 06:32, 24 August 2007 (UTC)