Can I comment out lines which have other comments?
/*
* comment 1
*/
$var = 0;
$if();
/*
* comment 2
*/
$var2 = 2;
Is there a way to comment out all these lines together? I often have a long function or logic and would like to comment out the rest for testing.
Have you considered skipping over the code by placing it inside an if(0) block?
For example:
<?php
if( 0 ) {
print("This code is 'commented' out");
... other commented out code is here ...
}
?>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With