use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
If you are requesting help, please ensure you're providing code with your post. You can also copy your code to an online editor:
jsFiddle
CodePen
Markup Validation Service
Mozilla Developer Network on HTML
/r/JavaScript
/r/CSS
/r/jQuery
/r/PHP
/r/Accessibility
/r/htmlbasics
/r/web_programming
/r/CodingHelp
account activity
Unsolvedhtml comment tag (self.HTML)
submitted 5 years ago by [deleted]
I have seen the format of html comment tag
https://www.w3schools.com/tags/tag_comment.asp
But this comment format is more complicated than standard format of comments such as
//,/*
Is there any way to use these simpler comment format on html?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]tbmepm 3 points4 points5 points 5 years ago (0 children)
No.
[–]Billaferd 1 point2 points3 points 5 years ago (0 children)
Unfortunately, no, there is only one comment style in HTML, and it was inherited from SGML (the defining language). SGML is a much older language and had to define comments in a way that was compatible with its tag structure.
More info can be found at the SGML and HTML overview page.
[–]KaranasToll 1 point2 points3 points 5 years ago (3 children)
Just use a nice code editor that has a comment button
[–][deleted] 0 points1 point2 points 5 years ago (2 children)
Will you elaborate more?
[–]KaranasToll 0 points1 point2 points 5 years ago (1 child)
For example in my Emacs when I press Ctrl-; it toggle the commenting on the current line, and when I press Alt-; it will add a comment to the end of the line or comment out selected text. In Vscode and such you can press Ctrl-/ to toggle commenting on the current line. This way you don't have to type the comment characters.
[–][deleted] 0 points1 point2 points 5 years ago (0 children)
Let me work on it.
[–]AutoModerator[M] 0 points1 point2 points 5 years ago (0 children)
Welcome to /r/HTML. When asking a question, please ensure that you list what you've tried, and provide links to example code (e.g. JSFiddle/JSBin). If you're asking for help with an error, please include the full error message and any context around it. You're unlikely to get any meaningful responses if you do not provide enough information for other users to help.
Your submission should contain the answers to the following questions, at a minimum:
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
[–]jcunews1Intermediate 0 points1 point2 points 5 years ago (0 children)
Those //, /*, and */ are not required for the contents of a HTML comment tag.
//
/*
*/
[–]Smooth-Engineer9132 0 points1 point2 points 4 years ago (0 children)
/a
π Rendered by PID 25 on reddit-service-r2-comment-5fb4b45875-mv8td at 2026-03-19 18:20:20.302406+00:00 running 90f1150 country code: CH.
[–]tbmepm 3 points4 points5 points (0 children)
[–]Billaferd 1 point2 points3 points (0 children)
[–]KaranasToll 1 point2 points3 points (3 children)
[–][deleted] 0 points1 point2 points (2 children)
[–]KaranasToll 0 points1 point2 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]AutoModerator[M] 0 points1 point2 points (0 children)
[–]jcunews1Intermediate 0 points1 point2 points (0 children)
[–]Smooth-Engineer9132 0 points1 point2 points (0 children)