![](https://upload.wikimedia.org/wikipedia/commons/thumb/4/43/Test_Template_Info-Icon_-_Version_%282%29.svg/50px-Test_Template_Info-Icon_-_Version_%282%29.svg.png)
Use this substitution to insert HTML comments (<!-- ... -->
) – hidden to readers – into Wikipedia pages.
Usage
[edit]{{subst:html comment|Lorem ipsum dolor sit amet}}
- ↳
<!-- Lorem ipsum dolor sit amet -->
- ↳
By default a space will be added before and after the given text. Use
{{subst:html comment|collapsed=yes|
Lorem ipsum dolor sit amet
}}
will generate
<!--
Lorem ipsum dolor sit amet
-->
In substitutable templates, use {{{{{|safesubst:}}}HTML comment|...}}
.
Notable cases
[edit]Using this substitution allows the expansion of MediaWiki commands inside HTML comments, where they would be preserved verbatim otherwise. Compare:
{{subst:html comment|{{subst:FULLPAGENAME}}}}
- ↳
<!-- Template:HTML comment -->
- ↳
and:
<!-- {{subst:FULLPAGENAME}} -->
- ↳
<!-- {{subst:FULLPAGENAME}} -->
- ↳
See also
[edit]- {{Example HTML comment}}
- {{Comment}}