Template talk:Date table sorting: Difference between revisions

Content deleted Content added
m Archiving 4 discussion(s) to Template talk:Date table sorting/Archive 2) (bot
Tag: Replaced
m Archiving 1 discussion(s) to Template talk:Date table sorting/Archive 2) (bot
 
(23 intermediate revisions by 10 users not shown)
Line 10:
}}
 
== [[:ce:Модуль:Dts]] ==
== Template-protected edit request on 8 December 2019 ==
 
Hello! Can someone help me fix the date format in Chechen? should be "2020 шеран 9 декабрь". [[User:Takhirgeran Umar|Takhirgeran Umar]] ([[User talk:Takhirgeran Umar|talk]]) 20:28, 9 December 2022 (UTC)
{{edit template-protected|Template:Date table sorting|answered=y}}
Please consider adding a text alignment option <code>{{!}}align=</code>, defaulted to the right (e.g.:<code><nowiki>align={{{align|right}}}</nowiki></code>). [[User:Guarapiranga|Guarapiranga]] ([[User talk:Guarapiranga|talk]]) 19:31, 8 December 2019 (UTC)
* I oppose this. What does alignment have to do with sorting? --[[User:Gonnym|Gonnym]] ([[User talk:Gonnym|talk]]) 19:57, 8 December 2019 (UTC)
:[[File:Red information icon with gradient background.svg|20px|link=|alt=]] '''Not done for now:''' please establish a [[Wikipedia:Consensus|consensus]] for this alteration '''[[Wikipedia:Edit requests|before]]''' using the {{tlx|edit template-protected}} template.<!-- Template:ETp --> [[User:Cabayi|Cabayi]] ([[User talk:Cabayi|talk]]) 20:01, 8 December 2019 (UTC)
 
== How to make date ranges sort to correct position in both ascending and descending displays? ==
== table-wide parameter? ==
 
Is there any way to make a [[MOS:DATERANGE]] sort to the correct chronological position in both ascending and descending displays? For example in [[Jack Deam#Filmography]] the date ranges sort by the first date in the range, which is correct if sorting oldest first but gives incorrect chronological order when using date sorting to display most recent at the top where it is the end of the range date that determines correct chronological order. [[Special:Contributions/213.18.145.207|213.18.145.207]] ([[User talk:213.18.145.207|talk]]) 13:44, 5 April 2023 (UTC)
Since this template is intended for use in making table columns sortable, it would be nice if it were possible to set a parameter at the level of the whole table so that options such as ''|format=dmy'', which is required to avoid US-centric dates, do not have to be repeated for each individual date entry? I have no idea if this sort of scope would work in this html/mediawiki mix. [[User:Boud|Boud]] ([[User talk:Boud|talk]]) 23:51, 29 February 2020 (UTC)
:I believe not although you might check at [[WP:VPT]]. As I far as I know, each column has a single sort key which is used for both ascending and descending ordering. For example, <code>2016–2022</code> cannot be sorted by 2016 in one direction and 2022 in the other. I don't think it matters much for the example given. If it were a big deal, two columns would be needed, one for the first date and another for the last. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 02:53, 6 April 2023 (UTC)
 
== Invalid date error for 2524 BC ==
:I support being able to set parameters <code>|format</code>, <code>|abbr</code>, and <code>|nowrap</code> at the table level. In addition the default format should be set by {{tl|use dmy dates}} if present.<br>[[User:Jim Craigie|Jim Craigie]] ([[User talk:Jim Craigie|talk]]) 04:34, 13 November 2020 (UTC)
 
The [[Decolonisation of Asia]] article has a table with a cell containing the date 2524 BC. This template throws an error if used with this date. [[User:Wtmitchell|Wtmitchell]] [[User talk:Wtmitchell|(talk)]] <small>(earlier ''Boracay Bill'')</small> 00:16, 4 January 2024 (UTC)
== Wrapping ==
:I believe the following works:
 
:*<code><nowiki>{{dts|2524|||BC}}</nowiki></code> → {{dts|2524|||BC}}
The explanation for the wrapping parameter is unclear. Does this template output non-breaking spaces by default, and this parameter change to normal spaces, or is it about allowing the name of a month to break across two lines? Presumably it’s default isn’t “off” as stated.<br>[[User:Jim Craigie|Jim Craigie]] ([[User talk:Jim Craigie|talk]]) 04:23, 13 November 2020 (UTC)
:The missing parameters 2 and 3 are for the month and day. The era (BC etc.) is parameter 4. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 00:38, 4 January 2024 (UTC)
:{{ping|Wtmitchell}} I should probably have notified you. [[User:Johnuniq|Johnuniq]] ([[User talk:Johnuniq|talk]]) 03:37, 4 January 2024 (UTC)
::Thanks. I applied fixed [https://en.wikipedia.org/w/index.php?title=Decolonisation_of_Asia&diff=1193505885&oldid=1192949085 here]. [[User:Wtmitchell|Wtmitchell]] [[User talk:Wtmitchell|(talk)]] <small>(earlier ''Boracay Bill'')</small> 04:39, 4 January 2024 (UTC)