WordPress.org

Ready to get started?Download WordPress

Forums

thememagic
Remove comments (4 posts)

  1. experc@experc.lv
    Member
    Posted 1 year ago #

    Hi
    I m having problems removing comments form below post(Leave a Reply, submit...). I have checked everywhere. Please tell how can i do that?
    Thank you

  2. Tara
    Member
    Posted 1 year ago #

    Just to make sure, do you want to remove the entire comment form or just the wording "Leave a Reply"?

  3. experc@experc.lv
    Member
    Posted 1 year ago #

    I want to remove entire comment form from any pages and posts like this which are showing in bottom.

  4. Tara
    Member
    Posted 1 year ago #

    try adding this snippet to your theme's functions.php

    // Removes from post and pages
    add_action('init', 'remove_comment_support', 100);
    
    function remove_comment_support() {
        remove_post_type_support( 'post', 'comments' );
        remove_post_type_support( 'page', 'comments' );
    }

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.