I used the auto mark complete when open in the wplms-customizer.php from this link...
https://wplms.io/support/knowledge-base/auto-mark-unit-complete-when-open/
However, it make more sense to me if the unit gets auto marked when the "Next" unit button is clicked. How can I do this ?
Thank you
For this first please remove the code that you added from the tip.
--------------
Now enable the setting from the wp-admin->lms->settings->Auto-mark unit complete when user proceeds to next unit, refer:
http://prntscr.com/e6yr88