Template:Advanced link

From Valve Developer Community
Revision as of 05:02, 24 April 2026 by Max34 (talk | contribs) (Removed styled mode and everything related to colors; added alt for accessibility and better copying)
Jump to navigation Jump to search
English (en)Deutsch (de)Esperanto (eo)Español (es)Français (fr)Suomi (fi)Hrvatski (hr)Magyar (hu)Italiano (it)日本語 (ja)한국어 (ko)Nederlands (nl)Polski (pl)Português (pt)Português do Brasil (pt-br)Русский (ru)Slovenčina (sk)Svenska (sv)Türkçe (tr)Українська (uk)Tiếng Việt (vi)中文 (zh)中文(臺灣) (zh-tw)
Template Documentation



Icon-translate.pngDocumentation language
...

This template creates a link with additional features. Primarily created as a basis for other link templates: game templates, program templates and external link templates.

Description

Parameters Description
| <Option>
| 1 = <Option>
Template display format:
  • If the value is empty, the standard option will be displayed: an icon with a link.
  • icon – Displays only the icon.
  • link – Displays only the link.
  • text – Displays link text only.
| icon = <image.png> The icon that will be displayed next to the link.
| size = <{w}x{h}> Icon size. Don't include "px". Default value is x16.
| external = <Empty> If this parameter is specified, the value of the {{{link}}} parameter will be treated as an external link.
Do not enter anything into this parameter, it must be left blank, otherwise it will break the template.
| link = <Any link> Internal Link. If the {{{external}}} parameter is specified, this link will be treated as external link.
| text = <Link text> The text that will be displayed for the link.

Child Templates Usage

These examples are written directly using this template, since the {{Portal 2}}, {{Idtech3}} and {{Cs2d}} do not currently use this template as their base.

Code Preview Description
{{Portal 2}} This is Portal 2! Link with icon.
{{Portal 2|icon}} This is Portal 2! Clickable Icon.
{{Portal 2|link}} This is Portal 2! Link without icon.
{{Portal 2|text}} This is Portal 2! Plain text.
{{Idtech3}} This is Id Tech 3! Link to Wikipedia article.
{{Cs2d}} This is CS2D! External link.
{{Cow|Half-Life|Example}} This is Example! External link. Unlike the previous examples, it uses a different parameter format.

Examples

Template:Portal 2 (not the actual one)
  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
{{Advanced link | {{{1|{{{show|}}}}}} | icon = Portal2 icon.png | link = Portal 2 | text = {{#switch:{{Language}}|#default=Portal 2|Ko=포탈 2}} }}
  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
{{Advanced link | {{{show|}}} | icon = Combine overwiki icon.png | external = | link = https://combineoverwiki.net/wiki/{{urlencode:{{{1|}}}|WIKI}} | text = {{{2|{{{1|Combine OverWiki}}}}}} }}