Learndash reset course/quiz progress on Enroll

477 Views Asked by At

I have expiring certifications(certificates) so I want users to take the course again after expired, but I cannot use Delete Course Data because I need the records that show the course was taken and has expired.

Background: Courses are not Open, because Open courses cannot work with expiry, so they are Free and behind a mandatory login.

By default, course progress remains after expiry and when user re-enrols in the course they already still have all progress (which I do not want progress retained).

What would the function be to reset course data (but NOT certificates), reset quizzes (anything else?) and mark incomplete as user enrols in course? I'm guessing there's a hook for Enrol and a function to reset course progress but I can't find them in the docs.

1

There are 1 best solutions below

0
On

The official answer is no, it cannot be done in Learndash. So you cannot combine re-enrolling with expiration.

"In principle, there isn't an option in LearnDash, after access expiration, to delete data but keep certificates."