Skip to content

Instantly share code, notes, and snippets.

@firasd
Created May 24, 2018 21:52
Show Gist options
  • Save firasd/6d57184a2c5af6c33e9761421ddb53f4 to your computer and use it in GitHub Desktop.
Save firasd/6d57184a2c5af6c33e9761421ddb53f4 to your computer and use it in GitHub Desktop.
Remove 'Mark Complete' button from lesson pages in Learndash course
<?php
add_filter('learndash_mark_complete', function($return, $post) {
$course_hide_markcomplete = 0;
if(learndash_get_course_id($post->ID) == $course_hide_markcomplete) {
$return = '';
}
return $return;
}, 10, 2);
?>
@mahesh-dubal
Copy link

Not working

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment