Unable to activate comments (reviews) on courses.

Home Forums Legacy Support Support queries How-to & Troubleshooting Unable to activate comments (reviews) on courses.

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #173730
    chinolz
    Spectator
    https://wplms.io/support/forums/topic/unable-to-activate-comments-reviews-on-courses/#post-173729 same problem
    #173731
    chinolz
    Spectator
    This reply has been marked as private.
    #173852
    Diana
    Participant
    @chinolz Try adding this code in wp-admin > Plugins > Editor > select wplms customizer plugin > wplms-customizer.php // Enable Comments forcefully in course add_action('init',function(){ global $post; if($post->post_type == 'course'){ wp_update_post(array('ID'=>$post->ID,'comment_status' => 'open')); } });
    #173863
    chinolz
    Spectator
    not working
    #173866
    chinolz
    Spectator
    does not work for global posts it only works if you specify the exact post id eg add_action('init',function(){ wp_update_post(array('ID'=>2927,'comment_status' => 'open')); }); any solution to make it global?
    #173991
    Diana
    Participant
    @chinolz, checked this number of times but could not find a valid reason behind this. This is not even replicating on my localhost. The reason behind this could be anything, a conflict or it is not detecting it as a post. Please add the code using the ID's
    #173995
    chinolz
    Spectator
    Cant use the Id the bug is in all lms courses, need to fix the wplms bug or find a quick fix for all posts
    #174050
    Diana
    Participant
    This reply has been marked as private.
    #174052
    chinolz
    Spectator
    its showing because i used quick edit to save posts and enable comments. What i need is a permanent fix so when moderators update course information the reviews dont get disabled
    #174053
    chinolz
    Spectator
    never mind Alex gave me different code and it seems to be working, review present front end and its disabled in backend
    #174188
    Diana
    Participant
    @chinolz, Okay, Closing this topic
Viewing 11 posts - 1 through 11 (of 11 total)
  • The topic ‘Unable to activate comments (reviews) on courses.’ is closed to new replies.