What is single line comment in PHP? Explain with syntax.
The single line comment tells the interpreter to ignore everything that occurs on that line to the right of the comment. To do a single line comment type //
or #
and all text to the right will be ignored by PHP interpreter.
Example of single line comment
<?php
#this is a single line comment
echo"this is an printing statement";
//this is also a single line comment
?>
Learn more about the similar topics:
Tutorials |
---|
PHP Comments |
Exercises & Assignments |
---|
No Content Found. |
Interview Questions & Answers |
---|
What is single line comment in PHP? Explain with syntax. |