Sometimes you may find that you want to leave a remark in your WML file to remind you how it works at some later date, or you may want to temporarily remove part of a file while you are testing something else. Comments are the answer.
A comment starts with the four characters
and ends with the three
. Everything that appears between
these two markers, including tags, body text, entities, and line
breaks, is ignored. Here are some examples:
<!-- A simple comment. --> <!--This is a comment that spans several lines.-->
<!-- A simple <!-- EMBEDDED COMMENT, NOT! --> comment. -->
Moreover, the two characters
-- can’t appear
within the body of a comment, only at the end, as part of the
If for some reason you want the sequence
in your body text, write it with an entity (which you would have to
do for the
You may be worrying about using comments. Surely they end up sending lots of extra data to the browser, and you keep being told how saving bandwidth is really important? Don’t worry: the WAP gateway removes all comments as part of its processing, so the browser doesn’t even know they exist.