Template:HTML comment/doc
Appearance
![]() | This is a documentation subpage for Template:HTML comment. It may contain usage information, categories and other content that is not part of the original template page. |
![]() | This template should always be substituted (i.e., use {{subst:HTML comment}} ). |
Use this substitution to insert HTML comments (<!-- ... -->
) – hidden to readers – into Wikipedia pages.
Usage
{{subst:html comment|Lorem ipsum dolor sit amet}}
- ↳
<!-- Lorem ipsum dolor sit amet -->
- ↳
Notable cases
Using this substitution allows the expansion of MediaWiki commands inside HTML comments, which would be preserved verbatim otherwise. Compare:
{{subst:html comment|{{subst:FULLPAGENAME}}}}
- ↳
<!-- Template:HTML comment -->
- ↳
and:
<!-- {{subst:FULLPAGENAME}} -->
- ↳
<!-- {{subst:FULLPAGENAME}} -->
- ↳
See also
- {{Example HTML comment}}
- {{Comment}}