Movatterモバイル変換


[0]ホーム

URL:


Jump to content
WikipediaThe Free Encyclopedia
Search

Template talk:Coord

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is thetalk page for discussing improvements to theCoord template.
Archives:1,2,3,4,5,6,7,8,9,10,11,12,13,14Auto-archiving period:12 months 
Template:Coord ispermanentlyprotected from editing as it is aheavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported byconsensus, editors may use {{edit protected}} to notify an administrator to make the requested edit. Usually, any contributor may edit the template'sdocumentation to add usage notes orcategories.

Any contributor may edit the template'ssandbox. Functionality of the template can be checked usingtest cases.


This template does not require a rating on Wikipedia'scontent assessment scale.
It is of interest to multipleWikiProjects.
Microformats
Coord is part of, or of interest to,WikiProject Microformats, which encourages the deployment ofmicroformats in Wikipedia, and documents them in the article space. If you would like to participate, visit theproject page.MicroformatsWikipedia:WikiProject MicroformatsTemplate:WikiProject MicroformatsMicroformats
WikiProject iconGeographical coordinates
WikiProject iconCoord is of interest toWikiProject Geographical coordinates, which encourages the use ofgeographical coordinates in Wikipedia. If you would like to participate, please visit the project page, where you can join the project and see a list of open tasks.Geographical coordinatesWikipedia:WikiProject Geographical coordinatesTemplate:WikiProject Geographical coordinatesGeographical coordinates
WikiProject iconGeography
WikiProject iconThis template is within the scope ofWikiProject Geography, a collaborative effort to improve the coverage ofgeography on Wikipedia. If you would like to participate, please visit the project page, where you can jointhe discussion and see a list of open tasks.GeographyWikipedia:WikiProject GeographyTemplate:WikiProject Geographygeography
WikiProject Geography To-do list:

Here are some tasks awaiting attention:
iconTo helpcentralize discussions and keep related topics together, all sub-template talk pages redirect here.
Articles for deletionThis template was nominated for merging. Please review the prior discussions if you are considering re-nomination:


Archives
Archive 1Archive 2Archive 3
Archive 4Archive 5Archive 6
Archive 7Archive 8Archive 9
Archive 10Archive 11Archive 12
Archive 13Archive 14


This page has archives. Sections older than365 days may be auto-archived byLowercase sigmabot III if there are more than 5.
Related pages

Placement of the center of a location?

[edit]

Greetings and felicitations. The section title is awkward, but I can't think of a better way to phrase it. In particular with cities (and other larger areas), what coordinates should I use—the geographic center of the area in question, or the business district/center of activity? —DocWatson42 (talk)04:06, 29 October 2023 (UTC)[reply]

Edit: An example:North Haven, Maine. One set of coordinates was in the infobox, and another at the bottom of the article (as is often the case with American municipalities and counties), which I moved to the infobox, to aid in comparing the two. The first points to the northern part of the island, near the (possible) geographic center of the island, while the second appears to point to the business district. —DocWatson42 (talk)04:14, 29 October 2023 (UTC)[reply]
Bumping. —DocWatson42 (talk)08:58, 17 May 2024 (UTC)[reply]
Bumping again, in part to avoid the archiving of this topic. —DocWatson42 (talk)18:07, 10 September 2024 (UTC)[reply]
@DocWatson42: Many settlements grew up around the place where two transport routes met, such as a crossroads, or a bridge over a river. I would pick that point, if it can be identified. --Redrose64 🌹 (talk)22:13, 10 September 2024 (UTC)[reply]
Okay—so the human, rather than the geographic, center (assuming there is one, and it can be identified)? —DocWatson42 (talk)22:23, 10 September 2024 (UTC)[reply]
Bumping. —DocWatson42 (talk)01:28, 24 December 2024 (UTC)[reply]

Question about the "city" parameter (repost)

[edit]

At what point does the size of the population stop mattering? I have been generally ignoring populations smaller than 10,000 and just entering the unmodified "city" parameter—is this correct? (Reposted from27 May 2023.) —DocWatson42 (talk)21:02, 10 September 2024 (UTC)[reply]

Bumping. —DocWatson42 (talk)01:29, 24 December 2024 (UTC)[reply]

Consequences of placing the template at the top of articles?

[edit]

Greetings and felicitations. Are there any consequences to placing this template at the top of articles—will it foul anything up? (I have a vague recollection of seeing a mention that it does, but would like specific and concrete information.) —DocWatson42 (talk)01:34, 24 December 2024 (UTC)[reply]

MOS:ORDER says to put it between the navboxes and categories; but if it has|display=title (withoutinline) it could, in theory, be placed almost anywhere (like categories). It's conventional to put it at the bottom. --Redrose64 🌹 (talk)23:10, 24 December 2024 (UTC)[reply]
I know the convention—I'm just wondering about the consequences of an alternative, mostly because this would put it where it displays, and make it easier to find. —DocWatson42 (talk)23:37, 24 December 2024 (UTC)[reply]
You run the risk of wikignomes (some armed with scripts and bots) moving it to the bottom again. --Redrose64 🦌 (talk)14:01, 25 December 2024 (UTC)[reply]

Help needed with "Script error: The function "coordinsert" does not exist."

[edit]

Hi, all! Can anyone help us over atcy:Nodyn:Coord, please? We're getting the following when we use Coord template within the Infobox historic site template. Coord works outside of the Infobox historic site template, and we've gotten around it by putting the Coord template at the beginning and hidden the paramater |coordinates for now within the Infobox (seecy:Venta Silurum for an example of all of this in action). Cheers!Xxglennxx (talk)14:38, 1 January 2025 (UTC)[reply]

@Xxglennxx: The EnglishModule:Coordinates has a coordinsert function, which is not present incy:Modiwl:Coordinates. --Redrose64 🦌 (talk)16:54, 1 January 2025 (UTC)[reply]
Thank you, @Redrose64. Where can I find coordinsert? Cheers!Xxglennxx (talk)19:17, 1 January 2025 (UTC)[reply]
@Redrose64 Not to worry now - I just recopied from en to cy and it seems to have fixed it! Why I didn't do that hours ago is beyond me! Thank you again! :DXxglennxx (talk)19:31, 1 January 2025 (UTC)[reply]

Broken!

[edit]

https://geohack.toolforge.org now gives 404.Jidanni (talk)11:21, 18 January 2025 (UTC)[reply]

Seems to work now. —hike395 (talk)12:54, 18 January 2025 (UTC)[reply]
Yes - raised issue on the Help Desk and it started working again soon after, though maybe coincidence.Rupples (talk)13:04, 18 January 2025 (UTC)[reply]

Broken - Feb 2025

[edit]

Getting a 502 when clicking on a coord link.

Steps to reproduce

  1. Click on a coordinates link, for example

{{coord|48|30|N|144|39|E|region:RU_type:isle_source:GNS-enwiki}}

48°30′N144°39′E / 48.500°N 144.650°E /48.500; 144.650

Expected

Navigate to mapping page

Actual

502 error with text:

Webservice is unreachableThe tool responsible for the URL you have requested, https://geohack.toolforge.org/geohack.php?..., is not currently responding.

— Safety Cap (talk)18:55, 21 February 2025 (UTC)[reply]

Test for valid format= parameter value may be needed

[edit]

Using|format=degrees by mistake results in blank template output: {{Coord|51|26|0|N|19|55|25|E|format=degrees|display=inline}} →51°26′0″N19°55′25″E / 51.43333°N 19.92361°E /51.43333; 19.92361. It would be helpful to test for valid parameter values and output an error message and category.

Note that this is not a hypothetical problem: you can see it atMount Baker Wilderness, where the coordinates are supposed to display in the text "Mount Baker (10,420 feet (3,180 m))," but|format=DMS is suppressing the template's output entirely. –Jonesey95 (talk)17:43, 5 May 2025 (UTC)[reply]

Coordinates displaying inline despite display=title

[edit]

Atthis article, the coordinates are displaying inline (and in the title) despite display=title being set. –Jonesey95 (talk)13:44, 14 May 2025 (UTC)[reply]

@Jonesey95: I see coords in the title only. --Redrose64 🌹 (talk)20:31, 14 May 2025 (UTC)[reply]
I see them displayed at the bottom, below the authority control template. I don't see them when I am logged out, though. Oh dear, I may have messed up something in my CSS. Ihaven't changed it in months, though. Hmm. –Jonesey95 (talk)23:19, 14 May 2025 (UTC)[reply]
When using my nrowser's "view page source" feature to show the HTML that has been served, I find that after the authority control box (a div element) there is a p element as follows:
<p><spanclass="geo-inline-hidden noexcerpt"><styledata-mw-deduplicate="TemplateStyles:r1156832818">.mw-parser-output.geo-default,.mw-parser-output.geo-dms,.mw-parser-output.geo-dec{display:inline}.mw-parser-output.geo-nondefault,.mw-parser-output.geo-multi-punct,.mw-parser-output.geo-inline-hidden{display:none}.mw-parser-output.longitude,.mw-parser-output.latitude{white-space:nowrap}</style><spanclass="plainlinks nourlexpansion"><aclass="external text"href="https://geohack.toolforge.org/geohack.php?pagename=Tata_Steel_Netherlands&amp;params=52.47839_N_4.59212_E_type:landmark"><spanclass="geo-nondefault"><spanclass="geo-dms"title="Maps, aerial photos, and other data for this location"><spanclass="latitude">52°28′42″N</span><spanclass="longitude">4°35′32″E</span></span></span><spanclass="geo-multi-punct">&#xfeff; /&#xfeff;</span><spanclass="geo-default"><spanclass="geo-dec"title="Maps, aerial photos, and other data for this location">52.47839°N 4.59212°E</span><spanstyle="display:none">&#xfeff; /<spanclass="geo">52.47839; 4.59212</span></span></span></a></span></span></p>
to which I've added some newlines for clarity. Something in your settings must be matching that.mw-parser-output .geo-inline-hidden selector, possibly with a higher specificity, and applying the declarationdisplay:inline causing it to become unhidden. It doesn't have to be a CSS file, although that's the usual place to start - it could be a Javascript file, and the problem there is that many people (myself included) import scripts from other people's user space, over which we have no control. If somebody out there has written a neat script to aid their work, and you have seen the benefits and decided to import it yourself, that's nice until the original author amends the script, at which point you also get the amendments, desirable or otherwise.
Perhaps the script author was working in fixing coords, maybe to trim downexcessive decimals and so wanted to find them easily so they could edit the correct section, without opening each section in turn. So they decided to enhance the script so that coords show up inline even for|display=title. You will have inadvertently inherited that new feature.
If you can't trace the script that is doung this, you may need to write a CSS rule to restore thatdisplay:none declaration. --Redrose64 🌹 (talk)10:32, 15 May 2025 (UTC)[reply]
I still can't believe we have all this in here, for the 5 users who want to customize this. We should really see about getting rid of it, it makes no sense. —TheDJ (talkcontribs)11:36, 15 May 2025 (UTC)[reply]
Thanks for the above. I blanked my vector-2022.js file, and the coordinates went away, so it looks like one of the .js scripts I am importing has been modified. FWIW, with scripts enabled, I see the above code, but with a closing /p and an additional<div>...</div> pair before the coordinates link, so it appears that the actual text of the coords don't get all that styling applied to them. Here's mine:
<p><spanclass="geo-inline-hidden noexcerpt"><styledata-mw-deduplicate="TemplateStyles:r1156832818">.mw-parser-output.geo-default,.mw-parser-output.geo-dms,.mw-parser-output.geo-dec{display:inline}.mw-parser-output.geo-nondefault,.mw-parser-output.geo-multi-punct,.mw-parser-output.geo-inline-hidden{display:none}.mw-parser-output.longitude,.mw-parser-output.latitude{white-space:nowrap}</style><spanclass="plainlinks nourlexpansion"><spanstyle="position: relative; white-space: nowrap;"></span></span></span></p><divstyle="background-color: rgb(255, 255, 255); padding: 0.2em; border: 1px solid black; position: absolute; top: 1em; left: 0em; display: none; z-index: 15;"><spanstyle="cursor: pointer;"><imgsrc="//upload.wikimedia.org/wikipedia/commons/thumb/5/55/WMA_button2b.png/17px-WMA_button2b.png"srcset="//upload.wikimedia.org/wikipedia/commons/thumb/5/55/WMA_button2b.png/17px-WMA_button2b.png 1x, //upload.wikimedia.org/wikipedia/commons/thumb/5/55/WMA_button2b.png/34px-WMA_button2b.png 2x"class="wmamapbutton noprint"title="Show location on an interactive map"alt=""style="padding: 0px 3px 0px 0px; cursor: pointer;">&nbsp;WikiMiniAtlas</span></div><aclass="external text"href="https://geohack.toolforge.org/geohack.php?pagename=Tata_Steel_Netherlands&amp;params=52.47839_N_4.59212_E_type:landmark"><spanclass="geo-nondefault"><spanclass="geo-dms"title="Maps, aerial photos, and other data for this location"><spanclass="latitude">52°28′42″N</span><spanclass="longitude">4°35′32″E</span></span></span><spanclass="geo-multi-punct"> / </span><spanclass="geo-default"><spanclass="geo-dec"title="Maps, aerial photos, and other data for this location">52.47839°N 4.59212°E</span><spanstyle="display:none"> /<spanclass="geo">52.47839; 4.59212</span></span></span></a>
I guess I could wolf-fence it, but I'll live with it for now unless one of you has additional insight. I scrolled through my .js script list, and I use a lot of them. –Jonesey95 (talk)13:47, 15 May 2025 (UTC)[reply]

Coords smashing into hatnotes

[edit]

On pages with long hatnotes, the coordinates overlays the other text. The screenshot is fromSpecial:Permalink/1300395254. My CSS is really weak, but maybe this is related to theissue above?RoySmith(talk)13:04, 14 July 2025 (UTC)[reply]

They should be shown as true indicators (what they are), and not artificially lowered, like inMediaWiki:Vector.css#L-13:#coordinates {position: absolute; top: 3.5em;Ponor (talk)14:21, 14 July 2025 (UTC)[reply]
@RoySmith: It's not a hatnote, it's the tagline. By default, it reads "From Wikipedia, the free encyclopedia". I guess you have some script or gadget installed that overrides this, making it somewhat longer. This might possibly be "Display anassessment of an article's quality in its page header (documentation)".
Anyway, the tagline and coords have a similar vertical position only in certain skins, and your screenshot is of Vector (legacy) skin, in a non-maximised window, thus constraining the usable width. If you look at the page in e.g.Timeless skin, you'll see that the coords are higher up. --Redrose64 🌹 (talk)19:14, 14 July 2025 (UTC)[reply]
Interesting, thanks. And just because I can't remember the last time I switched skins, I'm switching to Timeless to see how that works.RoySmith(talk)22:12, 14 July 2025 (UTC)[reply]

Very wide images

[edit]

On top (right) of the pageAskja I see:

Coordinates: 65°01′59″N 16°46′59″W

Clicking results in a map that has a very wide oval shape of the lake, while clicking65°01′59″N 16°46′59″W results in a more round shaped lake on the map.FredTC (talk)05:32, 18 November 2025 (UTC)[reply]

This looks like it might be a projection-related issue. I see the same problem atImuruk Lake, which is similarly far north. If you zoom all the way out from that lake, you'll seeLake&lang=en a projection instead of a globe. I don't know where to report this bug, but it is real. –Jonesey95 (talk)23:20, 18 November 2025 (UTC)[reply]
I can confirm the issue. These maps seem to be stretched out along the east-west axis.
I think the issue should be reported onm:Talk:WikiMiniAtlas and/or on theGitHub issue tracker. The developer ofWikiMiniAtlas,User:Dschwen, does not appear to very active on Wikimedia projects but may still receive ping notifications.~2025-32085-07 (talk)22:46, 21 November 2025 (UTC)[reply]
At 65.0304 latitude Δ 1° is 111,533 meter, but Δ 1° longitude is 13,718 meter. So Δ 1° latitude there is 8.13 times bigger than Δ 1° longitude. However that is not the factor that is used on this map (I estimate it to be 2 -2.5 times too wide). (something went wrong while measuring) --FredTC (talk)01:52, 22 November 2025 (UTC)[reply]

Coord vs WikidataCoord

[edit]

Can someone help me understand this? I have found that{{Coord|display=it}} seems to produce the same result as{{WikidataCoords|display=it}} on multiple different pages... Is this template now pulling from wikidata when no coords are supplied?Zackmann (Talk to me/What I been doing)16:44, 11 December 2025 (UTC)[reply]

@Zackmann08: since 2014, no? That'sSpecial:Diff/624928514Ponor (talk)16:53, 11 December 2025 (UTC)[reply]
@Ponor: appreciate you finding a specific diff for me. I guess what I'm confused about is why was{{WikidataCoords}} even made then? It looks like it was created in 2016.IF the same can be achieved here, can the 2 safely be merged or am I missing something...Zackmann (Talk to me/What I been doing)16:55, 11 December 2025 (UTC)[reply]
I hatted the duplicate discussion that you started atTemplate talk:WikidataCoord § Coord vs WikidataCoord. One discussion in one place please. SeeWP:MULTI. And you then immediately reverted the hat because I didn't give you an answer there. Have you no patience?
I wroteModule:WikidataCoord but I no longer remember exactly why I wrote it. But, a few minutes of poking about seems to indicate that I wrote it because{{coord}} doesn't support fetching coordinates from wikidata for an arbitrary qid. This works:
{{WikidataCoord|Q90}}48°51′24″N2°21′8″E / 48.85667°N 2.35222°E /48.85667; 2.35222
but this doesn't:
{{Coord|Q90}}Coordinates: Missing latitude
Invalid arguments have been passed to the {{#coordinates:}} function
Trappist the monk (talk)00:40, 13 December 2025 (UTC)[reply]
Felt it was appropriate to discuss on both templates since I didn't get any good responses in the other location. Appreciate you taking the time to explain the difference. That is very helpful.Zackmann (Talk to me/What I been doing)00:43, 13 December 2025 (UTC)[reply]
Trappist the monk given that the following DOES work, is there a reason not to merge these templates. I understand a straight redirect won't work, but a systematic merge...
{{Coord|qid=Q90}}48°51′24″N2°21′08″E / 48.8567°N 2.3522°E /48.8567; 2.3522
--Zackmann (Talk to me/What I been doing)00:46, 13 December 2025 (UTC)[reply]
Module:WikidataCoord came into being 8 May 2016 as a result of discussion atTemplate talk:Coord/Archive 11 § Using coord to inherit co-ordinates from wikidata. Support for|qid= in{{coord}} was added 16 November 2018 atthis edit toModule:Coordinates. So the apparent purpose of{{WikidataCoord}} was support of arbitrary qids.
Trappist the monk (talk)02:02, 13 December 2025 (UTC)[reply]

Edit request to complete TfD nomination

[edit]
Thisedit request has been answered. Set the|answered= parameter tono to reactivate your request.

Template:Coord has been listed at Templates for discussion (nomination), but it was protected, so it could not be tagged. Please add:

<noinclude>{{subst:tfm|help=off|1=WikidataCoord}}</noinclude>

to the top of the page to complete the nomination. Thank you.Zackmann (Talk to me/What I been doing)04:49, 13 December 2025 (UTC)[reply]

Note this was an automated (WP:TWINKLE) comment. I do think the template should be tagged, but I have intentionally wrapped it in<noinclude>...</noinclude> as I do NOT think this needs to show up on well over a million pages. If an admin disagrees, feel free to overrule me!Zackmann (Talk to me/What I been doing)04:51, 13 December 2025 (UTC)[reply]
Yeah, I'm inclined to agree. And I'm the guy who got in trouble over edit warring to un-noinclude TfD tags back when I started editing, and wroteWP:Templates for discussion/Noincluded tags... Anyway, Done* Pppery *it has begun...04:50, 15 December 2025 (UTC)[reply]
Thanks!!!Zackmann (Talk to me/What I been doing)05:08, 15 December 2025 (UTC)[reply]
Retrieved from "https://en.wikipedia.org/w/index.php?title=Template_talk:Coord&oldid=1327597934"
Categories:
Hidden categories:

[8]ページ先頭

©2009-2025 Movatter.jp