Home › Forums › Legacy Support › Support queries › How-to & Troubleshooting › Hide quizzes after finished course in WPLMS 4
Tagged: hide quiz finish course
- This topic has 20 replies, 3 voices, and was last updated 3 years, 6 months ago by Diana.
-
AuthorPosts
-
March 26, 2021 at 11:01 pm #348850gabrielcapiSpectatorHello, We have this Ticket , where you helped us to change with custom code this requirement, we want that a student can finish a course and keep seeing only the units, but not the quizzes after finish, I tried with the same code in my wplms-customizer.php file but it's not working, I'm still seeing the quizzes after finish a course. My websiteMarch 26, 2021 at 11:01 pm #348851gabrielcapiSpectatorThis reply has been marked as private.March 27, 2021 at 10:13 am #348969DianaParticipantThis reply has been marked as private.March 29, 2021 at 10:58 pm #349184gabrielcapiSpectatorThis reply has been marked as private.March 30, 2021 at 7:02 am #349299DianaParticipantThis reply has been marked as private.March 30, 2021 at 3:27 pm #349476gabrielcapiSpectatorWe understand that it does not come with the original version but to keep our business running the accreditation bodies that certified our courses require that students do not have access to the exams after completing a course, that's why you helped us last time with that requirement. Actually in version 3 you told us the same, but after you helped us with the custom wplms-customizer code. We beg you to help us or let us know where we can ask for a paid customization if possible. Thank you.March 31, 2021 at 12:54 pm #349768DianaParticipantI can try one more time, but in case I don't find any hook on which this custom code can be written, then I can't help you. Please give me some timeApril 1, 2021 at 2:59 pm #350103gabrielcapiSpectatorThat's great, thank you Diana! We hope you can help us.April 2, 2021 at 10:57 am #350305DianaParticipantTry this code
//Remove Quiz Once Course is attempted add_filter('bp_course_get_course_curriculum',function($curriculum,$course_id){ if(is_user_logged_in()){ $user_id = get_current_user_id(); if(bp_course_is_member($course_id,get_current_user_id())){ $check = bp_course_get_user_course_status($user_id,$course_id); //print_r($check); if($check >= 2){ $bp_course_template = BP_Course_Template::init(); $course_curriculum= $bp_course_template->get_curriculum($course_id); foreach($course_curriculum as $key=>$item_id){ if(get_post_type($item_id) == 'quiz'){ unset($course_curriculum[$key]); } } } } } return $course_curriculum; },10,2);
April 8, 2021 at 5:48 pm #351435gabrielcapiSpectatorHello Diana, I took a look and the quizzes are shown even with this code, so I guess is not working.April 10, 2021 at 6:46 am #351680DianaParticipantOn which course I can check the same on your site? Do share the URLApril 11, 2021 at 7:14 pm #351793gabrielcapiSpectatorApril 13, 2021 at 1:03 pm #352164DianaParticipantThis reply has been marked as private.April 14, 2021 at 9:46 pm #352478gabrielcapiSpectatorHello Diana, I mean in the course status page, there is where I need the quizzes hidden after finish the course. Thank youApril 14, 2021 at 10:51 pm #352487gabrielcapiSpectatorI see that in the course page the quizzes are not shown, can we remove the click to see the unit detail? Thank you again -
AuthorPosts
- The topic ‘Hide quizzes after finished course in WPLMS 4’ is closed to new replies.