Module: Citation/CS1/doc/Importing the Module:Citation/CS1 suite to your wiki Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.Anti-spam check. Do not fill this in! == Module:Citation/CS1/Date validation == [[Module:Citation/CS1/Date validation]] contains date format validation functions. The module understand dates like 1 February 2022 and seasons like spring, easter etc. The module will try to understand the date and then test if it is a valid date. Examples * {{Cite web|url=https://www.example.com|title=Example with a nonsense date |date= 57 Foo 2x21 |no-tracking=yes}} * {{Cite web|url=https://www.example.com|title=Example with a non existing date |date= 57 February 2021 |no-tracking=yes}} * {{Cite web|url=https://www.example.com|title=Example with a valid date |date= 27 February 2021 |no-tracking=yes}} * {{Cite web|url=https://www.example.com|title=Example with a future date |date= 27 February 2029 |no-tracking=yes}} Once a date is checked the module can reformat it if the template has provided the code for that * {{Cite web|url=https://www.example.com|title=Example with the date 27 February 2021 reformated by the module |date= 27 February 2021 |no-tracking=yes|df=ymd}} - the date is reformated with <code>|df=ymd</code> The module uses identifier letters: 'd' (day), 'm' (month), 'a' (anchor year), 'y' (year); second day, month, year have a '2' suffix. When a month is written with digits it is named 'm' and when the month is written with letters it is named 'M'. Since days and years are always written with digits there is no 'D' or 'Y'. So : <code>['ymd'] = </code> 2022-02-01 : <code>['Mdy'] = </code> February 1, 2022 : <code>['Md-Mdy'] = </code> January 20 β February 1, 2022 <Please add more text. Remember it may be used by by someone that is not an expert in coding and not a native English user. So better to add extra info and help links than to assume reader will know/understand.> === What to modify in ~Date validation on your wiki === The first thing to be changes in Danish Wikipedia is that in Danish a "." (dot) is used in dates. So in Danish February 1, 2022 would be written as "1. februar 2022" (with a dot after the day and with a small letter in month name). There is no pattern for Danish dates so : <code>['d.My'] = </code> 1. februar 2022 : and other variants using "d." etc. have to be created. See [[:da:Special:Diff/11035148]] (ignore the comments next to "['yMd']"). The diff above also contain a modification of the way hyphen and (n)dash is used. Danish Wikipedia does it differently than on English Wikipedia. However, the code added on Danish Wikipedi changes the hyphen/dash correctly but it leaves a message that something was changed even when it was not changed. So the code has to be changed. The second thing to change is that c. is written as ca. and nd (no date) would be u.Γ₯. (uden Γ₯r). Changed with this diff [[:da:Special:Diff/11035153]]. Summary: Please note that all contributions to Christianpedia may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here. You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see Christianpedia:Copyrights for details). Do not submit copyrighted work without permission! Cancel Editing help (opens in new window) Discuss this page