1<?php
2/*
3This is a multiple-lines comment block
4that spans over multiple
5lines
6*/
7?>
8
1<?php
2// Author : https://www.codedweb.org/
3// This is a single-line comment
4# This is also a single-line comment in unix and linux
5
6/*
7This is a Multi-lines comment block
8by this way you can add muliple lines on it.
9lines
10*/
11
12// You can also use comments to leave out parts of a code line
13$var = 2 /* + 12 */ + 2;
14echo $var;
15?>
1<?php
2// This is a single-line comment
3
4# This is also a single-line comment
5
6/*
7This is a multiple-lines comment block
8that spans over multiple
9lines
10*/
11
12// You can also use comments to leave out parts of a code line
13$x = 5 /* + 15 */ + 5;
14echo $x;
15?>
1// This is a single-line comment
2# This is also a single-line comment
3/*
4This is a multiple-lines comment block
5that spans over multiple
6lines
7*/
1//For a single line comment use //:
2//this is a comment too
3//for multi-line comments use /* and */:
4/* <--start of multi-line comment
5this is a comment
6
7this is a comment too (end of multi-line comment)-->*/