Preface

edit
This page is in the Category:Trainz Admin 'where all tools and special guidelines for Trainz will now be found! Questions: Post to: FrankB
  • If you don't know how to do something... Ask! (Skype is frank.a.bartus for ease of speed and clear communications.) I've got 60-70,000 edits on nine WikiMedia projects like this and am a fair template coder.
  • more suited to our Trainz needs and a comprehensive category system is mostly now in place!

The first section of this page contains in-line templates, the second special box display templates, most of which make a box with data within.

2014-0918 Wikibooks...
List of templates recently worked on (Latest Revision)
space tagging templates
  1. Template:Trainz-cat
  2. Template:TRSCat
  3. Template:Tref-pg  ???
utility and auto-categorizing mix
  1. Template:Trainz-stub
  2. Template:TRS-style
  3. Template:TRS-SubSubPg
  4. Template:TRS-sectstub
  5. Template:Trainz-stub
  6. Template:FAB-todo
  7. Template:R from Trainz
  8. Template:Trainz-sect-stub
  9. Template:Trainz-admin
  10. Template:Trainz-ref-page
  11. Template:Trainz-ref
  12. Template:Trainz-Admin
  13. Template:Trainz-page - (Fabartus moved page Template:Trainz-ref-page to Template:Trainz-page: reusing title for another admin template, this makes both more 'useable' and intuitive') (current) [rollback more than 10 edits]
  14. Template:Tre
edit
  • The most useful templates for general editing are in the next section following. Administration templates have been now listed last. This first group should have one representative on each page top and bottom respectively, and the header templates will shortly have the capability to thread page to page passing a convenient linking template (next section) with pretty-print code for each pass parameter.
  • Pages may be located in Trainz\pagename, if it is expected to be a much linked and much linked topic, but preferentially, that format should be for redirects to a page group (Book Division) where the page is listed in that TOC page.
  • Tutorials on CC and skills building tutorials should be in Content Creation and Introductory Trainz respectively.
  • Note this list mostly matches templates in use on the TrainzOnline pages
    The 'FUN' one's marked depreciated aren't used here
    1. Template:AM&C-top + Template:AM&C-bot - This is the workhorse for intermediate materials pages, such as Error Fixing, Windows application's HowTo, general theory and background (e.g. containers) and other introductory to intermediate knowledge topics.
    2. Template:FUN-top + Template:FUN-bot - This is the workhorse for introductory material, use AM&C templates for intermediate materials pages, and CC pages templates for advanced tutorials on Content Creation.
      1. Template:FUN-beg + Template:FUN-end - both depreciated
    3. Template:ORP-top + Template:ORP-bot - This is the workhorse for TrainzOnline enhanced materials and examples pages. Asset modification pages should be in AM&C or CC divisions; all pages in the references TOC should be technical references, not HowTo pages.
      1. The template pair is also used to tag Appendix pages, appropriate switches being passed.

    Template:TRScc-top + Template:TRScc-bot - This is the workhorse for Advanced material, use AM&C templates for intermediate materials pages. HowTo use Blender or Gmax basics belong in AM&C, other more refined instructionals in the CC pages.

    1. last there is: Template:TRS-page - depreciated; but one way to thread pages, Prev= '1', Next= '2', Thread Start (center link)= '3'(Main page is default, '4' =Main TOC, default is Trainz, or {{BASEPAGENAME}}, the Wikibook division TOC. The latter two can instead be used to fork navigation
      * TRS-page's logic and function have been worked into the header templates, which box the top of page links, while they looked unsightly floating above the header template.


     


    edit

    The two biggest time savers in this group link to the [[Trainz/refs/Notations#{{{1}}}|{{{1}}}]] and [[Trainz/Glossary#{{{1}}}|{{{1}}}]] pages.

    1. Template:TL
    2. Template:TA
    3. Template:Col
    4. Template:TR
    5. Template:Kp
    6. Template:TG
    7. Template:TOL
    8. Template:Center
    9. Template:N3V
    10. Template:Larger
    11. Template:Wp

    Editorial Aid Templates

    edit
    Aka, typing-aid templates

    These templates are used in-line to create links and display effects. They use mnemonic names, a standardized syntax necessary to simplify evaluation of the message on a page, on the one hand (Very short names and short, but consistent command parameter names or orders) and obviate the need for hiding subpage paths or displaying full paths for such pages on the other.

    • They also support sub-subpages, and a uniform pipetrick ability if an pretty-text override is in order to satisfy prose composition.
    • These features have been built-in to the several external link templates as much as possible as well
    • but Unicode and underscores in navigation must usually require a direct pretty-print override where the url has Unicode characters.
    • Several external link templates use syntax that allows directly linking to TrainzOnline Wiki pages, while a more general template allows pretty links to other (3rd party tutorials, for example) websites.

     

    edit
    general rule

    External Linking templates that include whitespace in the link forming parameter (the first part separated by '|' characters after the template name itself need to have UNDERSCORE characters instead of spaces.

    • Make sure to test such links, especially external links before thinking your job is done.
    • If you external link to another wiki such as Wikipedia or TrainzOnline, and the link uses a redirected page name, formulate the call to the proper full article name so it doesn't get disconnected if the redirected page title gets changed.
    • The exception to this is the N3V Wiki pages using double-quotes in their titles. In such a case, use the page title without the quotes, and if necessary, create a redirect page on that wiki.
    {{N3V}} — the workhorse of external linking to the N3V Wiki.
    • 1st argument is the page after 'url'
    • and symbolically link externally as longform: {{plainlinks | {{{1}}} | {{{2}}} }} so is the same as the longer wikimarkup external link:
    <span class="plainlinks"
    >[http://online.ts2009.com/mediaWiki/index.php/Trainz-build {{{2}}}]
    </span>
    • and literally form the link {{plain link|Trainz-build|Trainz-build tag version}}.
    Internal simple links
    • {{TL|Content Manager|Content Manager}} will appear as Content Manager
      • and symbolically link to a subpage as longform: [[Trainz/{{{1}}} | {{{2}}} ]]
      • and literally form the link [[Trainz/ContentManager|Content Manager]] forming a link to a direct sub-page of the Trainz Main Page.

    Similarly, {{TA}} forms a link to a sub-page off Trainz/AM&C AND {{TC}} forms a link to a sub-page off Trainz/Content Creation. But {{TR}} (references) and {{TG}} (glossary link) use an intermediate argument/pass parameter to modify the parsing.

    edit

    In organizing to group pages, simple linking templates were contraindicated once pages needed several sub-page levels and breaking the project into volumes only eliminated at most one such level. This spawned a new breed of template, which has some 'filtering smarts' or complimnetary coding to generate the desired links.

    • {{TG|Ca_to_Ez|Content Manager Plus}} (links to major section title in the Trainz Glossary) will appear as Content Manager Plus
      • and symbolically link as longform: [[Trainz#{{{1}}} | {{{2}}} ]]
      • so is the same as the longer: [[Trainz/Glossary#Ca_to_Ez|Content Manager Plus]]
    • {{TR|R|Content Manager}} will appear and link as Content Manager Plus
      • and symbolically link to a subpage as longform: [[Trainz_references/{{{1}}} | {{{2}}} ]]
      • so is the same as the longer: [[Trainz_references/{{{1}}} | {{{2}}} ]]
    void hidden text follows
    The next lines Are obsolescent...
    
    so not current planning, error fixing will be in Trainz AM&C volume. Error fixing will likely be Trainz AM&C/Trainz_Error_Fixing.
    • {{Tre|The Tag|is not permitted}} will appear as Template:Tre... other text hidden pending reworking schema
    void ends
    • {{Tws|Notepad++ in Trainz}} (Trainz Windows Application skills section title) will appear as Template:Tws
      • and symbolically link to a 'Notepad++ in Trainz' section of the reference page Trainz references/Windows_skills as longform: [[Trainz references/Windows_skills#{{{1}}} | {{{2}}} ]]
    • {{wp|Trainz|Trainz Article}} will appear as Trainz Article and symbolically link as longform:
    [[w:Trainz|Trainz Article]] to a Wikipedia article.
    edit
    {{plain link|full url of link|Pretty text}}

    'Plain link' forms a full external link for use in-line with a 'pretty print' text replacement.

    An example: The Trainz asset technology level is found in each assets' config.txt file and is called a "Trainz-build" tag number or sometimes the 'version number' which is strongly related to but different (it's directly dependent—since trainz-build tag value is defined by the code build of CCP when the asset is created. Both your actual software installed version (see titlebar of Post TS09-SP0 for this version number) and the asset's trainz-build are usually different) from the 'code build number or code version', which identifies the specific mix of software modules uniquely, also called the 'software build number' that is listed on each launcher screen.

    WARNING-1:
    When making a offsite 'External' link, click on the address bar and CTRL+A then CTRL+C to capture the proper full UNICODED address string.


    Best Practices::
    • Further, ALWAYS: Nav-test an external link when finishing a section. Perhaps especially when using an template to link.
    • While link formation is different and somethings might work, even Wikimedia (Wikipedia) link formation should be tested. If for no other reason to test the spelling and see if the name used is a redirect page name, in which case the correct name should be used and if necessary pipe tricked to display your chosen phrase.


    edit
    WARNING-2:
    • This link testing guideline is particularly important for links including punctuation characters or some non-English (still Western alphabets) titles, particularly known breakages occur in such as many N3V Wiki pages starting with and containing paired quotes. If there is no 'quote-less' redirect page to link on N3V's TrainzOnline, you are urged to create one.


    Editing, temp section

    edit

    LINKS CONTAINING THESE WILL NOT FORM A PROPER LINK as ASCII ' " ' characters in Wikimedia software parsing. The field breaks when one is encountered. Hoover your mouse tooltip over and compare:

    and is the literal:

    <span class="plain links">[http://online.ts2009.com/mediaWiki/index.php/%22script-include- able%22_container script-include-table_container]</span> (Full manual essence plain link would form)

    {{Plain link|http://online.ts2009.com/mediaWiki/index.php/"script-include-table"_container|script-include-table_container}}


    huh
    • but is the literal:

    {{Plain link|http://online.ts2009.com/mediaWiki/index.php/"script-include-table"_container|script-include-table_container}}

    • Literally: {{Plain link|http://online.ts2009.com/mediaWiki/index.php/"script-include-table"_container|script-include-table_container}}
    • Literally: {{Plain link|http://online.ts2009.com/mediaWiki/index.php/%22script-include-table%22_container|script-include-table_container}}

    ...

    • Q.E.D., as described, those four extra characters in the link make a difference. Further, this advisory does not just apply to web links containing '"', but to other characters as well used in the international conventions (likely Unicode) of the World Wide Web. It has not been evaluated whether quote leading pagenames herein will even link properly, since this site uses Common.css and Common.js files and processes, whereas the N3V TrainzOnline Wiki does not.

    TrainzLinkNeeded

    edit
    {{TrainzLinkNeeded|Dead or missing url needing researched|Pretty text}}
    'TrainzLinkNeeded' is meant to be replaced by 'Plain link' when a valid url is found. It can also be inserted as {{TrainzLinkNeededZ||Pretty Text}} where the double pipe fills in the url of the message page {{Trainz Link Needed}}, as an aid to both writers and readers. The template automatically categorizes pages to the maintenance tracking category Category:Trainz Links Fixups needed.

    TrainzTip

    edit
    This template makes a tip box like this:
    Example code: {{TrainzTip|...Some description of the lack or needs or just to flag where work}}
    ...Some description of the lack or needs or just to flag where work


    need I say more? // FrankB
    The below templates are standard MetaWiki general purpose templates ported into Wikibooks. FrankB 17
    55, 21 June 2013 (UTC) says I'll likely workup a customized version of some for Trainz so if you want something soon, drop me a note. For now, use the in-page template {{FAB-todo|Some description of the lack or needs or just to flag where work is needed— so perhaps someone else can pick it up before you can return!}}

    Wikibooks Standard Templates

    edit

    While use of these templates is not discouraged, they assume you will be back later to edit again and continue the work since they do not place pages into a Trainz Maintenance sub-cat.

    TODO

    edit
    {{TODO|Text of task}}

    Flag pages or sections that need some work with: {{TODO|Some text describing the task.}}

    Clipboard

    To do:
    Some text describing the task.


    Use with some caution as it adds a link to the page in the Wikibooks-wide TODO category.

    Info

    edit
    {{Info|Some interesting information}}

    Provide some supplemental information set off with: {{info|Some interesting information}}

    Warning

    edit
    {{Warning|Something to worry about or be careful of}}

    Warn the reader of something they might do wrong with dire consequences with: {{warning|Text of the warning.}}

    Danger

    edit
    {{Danger}}

    Warn the reader of something they might do that could have catastrophic results with: {{mbox|type=warning|msg=This action may cause irreparable harm to your installation!}}

    Example

    edit
    {{example}}

    Visually set off an example with {{example|Text with markup for the example}}

    Example:

    This is a sample example

    Code

    edit

    Set off sections of code, particularly for scripts. Wikibooks has an extensive set of enhanced templates for code markup with documentation. If the example is short, preface each line with a space to achieve a fast page wide emphasizing presentation

    • XML Example
      .

    Incomplete

    edit

    {{Incomplete module}} Flag a page as a work in progress with: {{Incomplete module}}

    Page to page linking

    edit
    For now...
    Use the standard Wikibooks template {{chapter navigation}} template so with Previous page= 'Installation Under Microsoft Windows' and next page= 'Installing Service Packs' the template, which goes on the page bottom above the page category and will look like:

    {{chapter navigation|Installation Under Microsoft Windows|Installing Service Packs}} and {{navigation|Installation Under Microsoft Windows|Installing Service Packs}} and display both top and bottom (Look here in those two places)

    Administration templates

    edit
    • Placing {{Trainz-Admin}} on a page top makes it part of the auto-category Category:Trainz Admin and displays the message box notice above. This has more general use than might be summarized here. With this and all templates, familiarize yourself with their usage—normally a lot of thought goes into writing such usage for lay-editors.
    • Placing {{Trainz-page|Previous|Next}} will link Trainz pages page to page (threading them like {{Chapter navigation}} but not making it's own links, instead...) using the category:Trainz linking templates passed with full pipetricked links. See the glossary page to see how it manifests as a footer and a nav-link above the page title box—with links in both places.
    • The general header template {{TRS-hdrbox}} will take such pass parameters from the Trainz divisions page header templates soon, with an option to link both up and down as well, including off-site.

     

    • Placing {{Trainz-stub|date}} or {{TRS-sectstub|date}} on a page auto-categorizes it to Category:Trainz pages needing attention (stubs) and displays a message box warning readers the page is unfinished. ALL STUB auto-categorizing (maintenance) templates should have a date defined in yyyy-mmdd form, AND can take another parameter suggesting what needs done. (this need not display, some do, some don't, some do either. If they don't, the text you outline as the TO-DO List disappears into the bit bucket — until someone edits the section, then the list is there to read.
    • Place {{TRS-SubSubPg}} at page bottom when breaking a topic into multiple pages, the parent (sub-)page then should reference the sub-sub-page. In Wikibooks terms, the set parents and children are a Module. This auto-categorizes the page into a comprehensive list category:Trainz Sub-Sub-pages.

     

    Redirect pages templates

    edit
    • Place {{R from Trainz}} on redirect pages to other Trainz Division pages, including when moving a page (edit in after the move) to auto-categorize and list Trainz redirected pages or aliases (e.g. CM and CMP both redirect to the Content Manager page, Layout to Route, so useful to use redirects at times.) The template must be placed immediately after the page redirect instruction link and on the same line as in:
    #redirect [[Trainz/Content Manager]] {{R from Trainz}}
    as for CM and CMP are formulated
    
    • Other redirect templates are used similarly, though most are formatted to {{R to TRS-Book Division}}.
    Place these IN the redirect page --on the same line as the terminal ']]' to auto-categorize the redirect page to a admin category. Each Maybe given a pipetrick to sort the 'pagename' being redirected to alphabetize better.
     
    • Similar: {{R from Trainz alternative name}} - for pages which have been given 'better' (more searchable) names or aliased for easing searching. This takes the 'bad' title from the main category.

    This page is a redirect from a Wikibooks Trainz page which either has been moved, or renamed as part of the Trainz Asset Management and Creation (AM&C) division of the Trainz Wikibook.  

    Category tagging templates

    edit

    Suggest not creating a category without consultation, it is likely the group you suggest has already been covered.

    • Place {{Trainz-cat|Purpose of the category page in some detail}} — use only on categories to demarcate and auto-categorize them as Trainz pages. The category will auto-default to trainz maintenance unless given a value in the control parameter 'noMaint' like: | noMaint= 1 .

    Preliminary category tree

    edit
    outline of category tree (temp here)
    temp
    whilst working out something started now missing.

    See also these Categories:

    Volume parents

    Category:Book:Trainz

    Admin pages
     
    Installation Under Microsoft Windows · Installing Service Packs