User:Skybike/Template:This months newsletter

From FlightGear wiki
Jump to navigation Jump to search

FlightGear Newsletter December 2024

The following template description is not displayed when the template is inserted in an article.

This sandbox experiment is based on User:Johan G/Template:This months newsletter.

If we decide to publish it I would suggest a more general name like "Template:Newsletter link" instead of "This months newsletter" as you can change the date here.

Goal

This template will link to the FlightGear Newsletter. If it does not yet exist this template will show a red link that when clicked will load a FlightGear Newsletter example with common headings, templates and categories already there, as well as some helpful comments for the editor. It is multilingual and supports custom

Usage

{{:User:Skybike/Template:This months newsletter |date= |link= |create= |subpage-to= |lang= }}

All parameters are optional

date
Default is current date. But you can choose a different date in the form YYYY-MM (like 2024-12).
link, create
Alternative name for the printed link to an existing Newsletter and to not existing Newsletter (by default "FlightGear Newsletter December 2024" and "Create FlightGear Newsletter December 2024")


Advanced Usage


All parameters are optional

date=
  • Default is now. More expressions are 2019-6, January 2020, next month, last month, +1 month, +8 month, +8 months, -8 days,,...
  • Only english therms are accepted, März 2018 or nächster Monat do NOT work, nowhere.


link= / create=
  • Shown as blue link text linking to an existing newsletter (link=) and creating a new one (create=):
    • "link=abc|create=def" shows "Abc" or "Def"


  • There are optional explanatory black texts around the blue link. Both are empty by default. You can define them by a "/" slash in the way "link=black/blue/black" "Black blue black"
    • Only the first one: "Write/me" shows "Write me"
    • Both texts: "Write/me/now" shows "Write me now"
    • Only the last text: "/me/now" shows "Me now"
    • No text: "Me" shows "Me"



subpage-to
Create the next newsletter as a subpage to subpage-to instead of as a separate page. Can be used for sandbox experiments as a subpage to your user page.
lang
This template has {{LangSwitch}} - overwrite that at subpages by entering en, de, fr, es, ca,...

Examples

{{This months newsletter}}

FlightGear Newsletter December 2024

(if it exists: FlightGear Newsletter May 2017 and if not Create FlightGear Newsletter May 2000


In {{newsletter-header}} we would use link= and create= to replace the default text:

{{This months newsletter|link=Please help us write/the coming edition!|create=Create the coming Newsletter edition}}

Please help us write the coming edition!


On translated pages (like De/Newsletter) you can link to last months english newsletter via:

{{This months newsletter |date=last month |lang= en |link=Add your article to the english/name |ceate=Create English  newsletter}}

Add your article to the english FlightGear Newsletter November 2024

Known issues

  • The first letter of "create=" and "link=" is always a capital letter
  • text//text and text/ does not work as you need a link text. Use text/name/text instead (or don't use link= and create= at all).
  • You can't combine the magical word "name" with other words than "create" and "read" within the blue link ("create=ab/cd name ef/gh" or "link=ab name" does not work). Type the newsletters name manually or define these words as black text using "/" slash
  • time= only works with english language, try to use international "YYYY-MM" (2018-12) whenever possible to help translators.
  • "name" and "read name" and "create name" are english codewords but have translated output. |create=bitte/create name/, um ihn zu füllen|lang=de
  • The internal wiki server may need some time (up to minutes) to index new pages. This template still shows the "create" link during that time.

Technical notes

The template will preload a subpage (User:Skybike/Template:This months newsletter/Newsletter example) to this template with a FlightGear newsletter example for the editor that clicks the link. Visit mediawiki.org to get more information.

You can use the following parameters on the preload subpage:

  • $1 for month (01,02,...12)
  • $2 for Year (like 2024).
  • $3 for current release YYYY.V, now 2020.3. See {{current release}} as source.


Define a subpage with this template (here to [[User:DeleteMe/FlightGear Newsletter December 2024]])

{{This months newsletter|subpage-to=User:DeleteMe}}

Create FlightGear Newsletter December 2024

Related templates