Anonymous edits have been disabled on the wiki. If you want to contribute please login or create an account.


Warning for game developers: PCGamingWiki staff members will only ever reach out to you using the official press@pcgamingwiki.com mail address.
Be aware of scammers claiming to be representatives or affiliates of PCGamingWiki who promise a PCGW page for a game key.

PCGamingWiki:Editing guide/Advanced editing techniques

From PCGamingWiki, the wiki about fixing PC games
< PCGamingWiki:Editing guide
Revision as of 17:35, 3 October 2023 by Aemony (talk | contribs) (created page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This page is intended for more advanced editors and details tips and tricks as well as techniques that can be used to achieve a more specialized purpose. Newcomers and beginners can often skip this page and continue straight to Conclusion and examples.


Display page content temporarily

The {{DisplayTemporarily}} template can be used to display a temporary message or information on a page, and tracked (for later removal) through a Cargo table.

This allows for temporary exposure of information such as, e.g.:

  • Fixboxes/issue sections only relevant for a while after the release of a patch.
  • Key points or similar notes about temporary measurements needed, or future events (e.g. service shutdowns) of a game.

Note that the data will also be hidden when previewing the page if the current date is outside of the specified range!


Syntax

{{DisplayTemporarily|from= December 1, 2019 (optional) |to= January 1, 2020 (optional) |data= {{ii}} Online services will be unavailable during the month of December. }}
  • from start date of when to display the information. Defaults to January 1, 2019 if omitted (meaning there is no start date).
  • to end date of when the information should be hidden again. Defaults to January 1, 2030 if omitted (meaning there pretty much is no end date).
  • data is the data that will be presented between the specified dates.
    • data= can be omitted, in which case the "first unnamed parameter" of the call will be used instead.


Numbered lists + Preformatted text

Wiki markup dislikes preformatted text blocks in numbered lists. Specifically the newlines in the preformatted text blocks interferes with the wiki markup for the numbered lists so that a new list is created underneath the preformatted text block. Use pure HTML instead[1] since it's much easier to work with and gets the job done the right way.

In the below example the third and fourth steps would begin anew as step 1 and 2.

# First step
# Second step
<pre>This is a
block of code</pre>
# Third step
# Fourth step

Sample:

  1. First step
  2. Second step
This is a
block of code
  1. Third step
  2. Fourth step

Solution

In this example the numbered list order is tracked properly and the third and fourth steps would appear correct.

<ol>
<li>First step</li>
<li>Second step</li>
<pre>This is a
block of code</pre>
<li>Third step</li>
<li>Fourth step</li>
</ol>

Sample:

  1. First step
  2. Second step
  3. This is a
    block of code
  4. Third step
  5. Fourth step


References