Viewing 3 replies - 1 through 3 (of 3 total)
  • //

    <?php //comments_template(); ?>

    Thread Starter writerhoward

    (@writerhoward)

    I commented out this PHP code:

    // <?php comments_template(); ?>

    which was within this code:

    <?php edit_post_link(‘Edit this page’,'<p>’,'</p>’); ?>
    // <?php comments_template(); ?>
    <?php endwhile; endif; ?>

    After saving it and viewing the page the code’s on, the comment boxes didn’t appear but the “//” did in their place.

    Any idea why?

    Sorry, I always get in trouble because I don’t like to write long posts.
    Q: what is the “comment” out for PHP?
    A: //

    Example: <?php //comments_template(); ?> <– this is commented out, notice the // in the code!

    <?php comments_template(); ?> <– this is NOT commented out

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How can I comment out this php line?’ is closed to new replies.