Editing Guide/Patterns: Difference between revisions
No edit summary |
No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
== Embedded Subpages == | == Embedded Subpages == | ||
Common use cases: DLC, memes with some distinct examples that need categorising differently. | |||
In some situations you have something which is small enough it should really just be a section of a larger article, but also it is distinct enough it should really have its own categories, without them all being mixed into the larger article. | In some situations you have something which is small enough it should really just be a section of a larger article, but also it is distinct enough it should really have its own categories, without them all being mixed into the larger article. | ||
Line 17: | Line 18: | ||
* If the parent article needs context for the subpage, you can use <code><<nowiki />includeonly></code> tags to have parts that don't appear when you are on the subpage itself, like a subtitle for the section. Example: the title on [[Japanese_Mispronunciations/Sun_Deer]]. | * If the parent article needs context for the subpage, you can use <code><<nowiki />includeonly></code> tags to have parts that don't appear when you are on the subpage itself, like a subtitle for the section. Example: the title on [[Japanese_Mispronunciations/Sun_Deer]]. | ||
* If making links to the section/subpage, use <code>{<nowiki />{EmbeddedSubpageLink|Parent|Subpage}}</code> to link to it, this will link to the section, unless you are *on* the subpage, where it'll be a self-link. This makes it work nicely in navboxes and the like where you want it to be a self-link for clarity they are on that page. | * If making links to the section/subpage, use <code>{<nowiki />{EmbeddedSubpageLink|Parent|Subpage}}</code> to link to it, this will link to the section, unless you are *on* the subpage, where it'll be a self-link. This makes it work nicely in navboxes and the like where you want it to be a self-link for clarity they are on that page. | ||
* Add a note to editors on how to edit the subpages, as it's a bit non-obvious. E.g: <code><<nowiki/>!--- If you want to edit these subpages, the easiest way is to scroll down to the "Templates used on this page:" section below here and click the edit link next to the subpage you want. --></code> |