Jump to content

Template talk:Infobox spring

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

New look?

[edit]

I've been working on a new version of the infobox and I would like some consensus before I change the current template. You can see an example of what I have in mind here. One of my goals is to change some of the parameter names so that they conform with names used by other infoboxs for geological features, such as {{Infobox mountain}} and {{Infobox protected area}}, but that can wait a bit.

If you know of other editors who might be interested in this discussion, please invite them to participate in this discussion. –droll [chat] 18:38, 18 October 2010 (UTC)[reply]

Looks good to me!
Epolk (talk) 03:48, 19 October 2010 (UTC)[reply]

Hidden script error

[edit]

I am trying to fix the following three articles which have been stuck in Category:Pages with script errors for a couple of days:

There is no visible error in these pages but each is in the above hidden tracking category. It is not a caching issue because there really is an error as can be seen by searching the html source for "Lua error".

The problem is that Module:Coordinates function convert_dms2dec line 232 calls Module:Math function _precision which gives a runtime error at line 172. That happens because the parameters passed to function convert_dms2dec are empty.

Previewing the following in a sandbox is sufficient to generate the error:

{{Infobox spring
| coords = {{coord|12.3|45.6}}
| map = Example.jpg
}}

It looks like the following in Template:Infobox spring gives the error with the above example. This is in code to use {{Infobox map}}.

    | lat = {{#Invoke:Coordinates|dms2dec<!--
		    -->|{{ifempty|{{{lat_NS|}}}|N}}|{{{lat_d|}}}|{{{lat_m|}}}|{{{lat_s|}}}}}
    | long = {{#Invoke:Coordinates|dms2dec<!--
		    -->|{{ifempty|{{{long_EW|}}}|E}}|{{{long_d|}}}|{{{long_m|}}}|{{{long_s|}}}}}

A fix is to use the following.

{{Infobox spring
| lat_d = 12.3
| long_d = 45.6
| map = Example.jpg
}}

Questions:

  • What should be done in the three articles to fix the errors?
  • Can something be done to either not generate the hidden error, or to make it visible?

Ping JohnBlackburne who also works on fixing articles in the tracking category. Johnuniq (talk) 01:08, 23 February 2017 (UTC)[reply]

I had a look at them when they appeared, and convinced myself that there was no error; that it was one of those where a template is broken but rapidly fixed, and a few pages get added to the category while this happens. In this case the breakage was the addition of the TfD notice, as the time they were added to the category matched that.
If you have found an error though it would make sense to fix it. Unfortunately the bug with hidden categories means you can't see if it fixes it in preview, you have to apply the fix and save it to see if it works. But this seems a reasonable thing to try in only three articles.--JohnBlackburnewordsdeeds 05:44, 23 February 2017 (UTC)[reply]
I had a go at fixing Puyehue Hot Springs with mixed results. Using a proper location map makes the error visible. Adding {{coord}} does not make it go away. Adding lat_d and long_d fixes the map and eliminates the error, ignores {{coord}}, but then the inline/title coords are badly broken.--JohnBlackburnewordsdeeds 11:20, 23 February 2017 (UTC)[reply]
Fixed the coords – the region was not a proper coords region and was linked which was breaking things. A very odd way to do it, assembling the coords from a dozen parameters in the infobox. Much better to use a {{coord}} if one is provided.--JohnBlackburnewordsdeeds 11:33, 23 February 2017 (UTC)[reply]
Thanks, you have fixed the three articles. Frietjes might look at the template later and see if it would be worthwhile tweaking it so there either is no error, or the error is visible, for the "sufficient to generate the error" example above. Johnuniq (talk) 02:38, 24 February 2017 (UTC)[reply]
 Fixed The code, above, is obsolete. I just passed the parameters to {{Infobox map}} directly. Hopefully that should prevent future problems. —hike395 (talk) 07:54, 24 February 2017 (UTC)[reply]

mapframe vs pushpin map vs map

[edit]

The onByDefault logic for mapframe here only takes pushpin map into account - not the map as well. Should we drop it in case either of these exist? --Joy (talk) 12:20, 1 November 2024 (UTC)[reply]

mapframe-zoom default 5

[edit]

This level of default zoom seems very much duplicating the idea of country pushpin maps with smaller countries.

A spring is not typically a large geographic feature, so a more zoomed in map seems to me like it would be a more sensible default. --Joy (talk) 12:22, 1 November 2024 (UTC)[reply]