A great way to comment your code!

Here is something useful that I created.

If I develop a site and need to output data for debugging, I will have to constantly print arrays.
At some point during coding, I’ll have to comment some code out with the good ‘ol forward slashes ‘//

So I came up with this:

/* * /
echo '<pre>';
echo '</pre>';
/* */


Notice the space between the second * and the /

Want the code to show? Delete the space.

Nice and simple.

The Core Team
Editorial Staff Members at 'corePHP'
Editorial staff for the Core Technology Blog for 'corePHP' - news, views insights and advice for e-commerce, marketing technology , web design and development.

3 thoughts on “A great way to comment your code!

  1. rod

    Hello comrade! What’s up?
    Thanks for such a nice tip. I just tried that one and it worked properly. This tip is really useful.
    Keep up the good work, pal.

  2. RaiulBaztepo

    Very Interesting post! Thank you for such interesting resource!
    PS: Sorry for my bad english, I’v just started to learn this language 😉
    See you!
    Your, Raiul Baztepo

Comments are closed.