Got a question about this topic?
Head on over to the Forum!

  • You can use this space to suggest improvements to the help page.

How do you make templates with fields for example

 {{Wikia template
 |Gaming =
 |Stuff =

Need help with this problem and the tutorial does NOT explain --Cs california 06:22, 21 January 2009 (UTC)

If you're just wanting to insert the text with the code similar above, write it like that on the page to be preloaded. If you are asking how to make a template using parameters, see Help:Template parameters. Kirkburn (talk) @fandom 14:55, 21 January 2009 (UTC)

I am attempting to create a new template titled "Infobox video game", similar to that used on Wikipedia. As stated in the directions, I am supposed to look for a page titled "Template:Example" and click on "Create" to create my template, correct? However, I cannot locate this page and instead created a page called "Template:Infobox video game". I write the following code onto the page:

{{Infobox video game
| name       = 
| image      = 
| imagewidth = 
| caption    = 
| developer  =
| publisher  =  
| platforms  =
| released   =
| genre      =
| modes      =
| ratings    =

When I click publish and try to insert this template onto a page, I get an error saying "Template loop detected: Template:Infobox video game". I must be doing something wrong. What should I do? Pac-Man1096 00:00, April 4, 2012 (UTC)

Page needs writing tips Edit

There are a few things that preload templates can not preload unless the user uses special care. See the following example.


To preload a <noinclude>...</noinclude> section, some creativity is involved. Also, some preload templates are littered with wanted pages like a wanted /doc.

It would be nice if there were a <preload>...</preload> tag that could wrap preload templates to help them behave better. Lady Aleena (talk) 11:53, January 10, 2018 (UTC)

I just tested a way to keep preloads from showing anything except the raw wikitext.

<noinclude><pre></noinclude>The preloaded text starts here.
The preloaded text ends here.<noinclude></pre></noinclude>

The only problem is that the first closing </noinclude> and the last <noinclude> shows.

However, when the page is preloaded, the <pre> tags do not get preloaded. I just wish there were a cleaner way for preload pages to work without creating a mess. Lady Aleena (talk) 12:20, January 10, 2018 (UTC)

The <preload>...</preload> tag could be a combination of <noinclude> and <pre> in one tag.

If <includeonly>...</includeonly> tags are used, users will not get an idea of what is being preloaded without viewing the source. Lady Aleena (talk) 12:24, January 10, 2018 (UTC)

Hi Lady Aleena, preloaded templates are used to improve the user experience of adding a template into an article via source editor. Usually, they are used by editors who are unfamiliar with the wikitext environment.
  • The situation where a user wants to preload a template and wants to keep the <noinclude> tag is extremely rare, and so the hack doesn't need to be in the main article.
  • A 'preload' tag may be interesting - it would certainly ease the inconsistencies with includeonly and noinclude. Feel free to send in the feedback via Special:Contact.
  • Lastly, I think you are overcomplicating things for the average use case for preloaded templates. Users using a preloaded template should not be bombarded with includeonly or noinclude tags - that should be within the template itself and not in the preloaded content. I think your use case is for the Templates Wiki, where there may be a need to preload a Template: namespace page with such tags - but this is an isolated situation and this tool may not be the right one for your wiki. noreplyz 13:13, January 10, 2018 (UTC)
I am detangling preloaded template documentation, sandboxes, and testcases. There are a lot of noinclude and includeonly tags in them that are preloaded onto the page. My first example came from a template sandbox preload. There are a lot of things on templates that have noinclude, includeonly, and even onlyinclude (rare). So something to make tags like that easier to preload would be helpful. Who knows, one day someone might find a way to preload a template using parameters.
So while this is just a small edge case for preloaded subpages of templates, it might still be a good idea to add a section on the hazards of preloading like how one must be creative if a preload would contain one of the above tags. Lady Aleena (talk) 07:59, January 12, 2018 (UTC)
The article is not about preloading the actual template, but preloading the transclusion of one. You're not meant to include those tags in these, because the tags would end up in articles and that is rarely the case. noreplyz 12:46, January 12, 2018 (UTC)