I have a course set up where students complete a quiz to get a certificate. Because of the target audience the teacher should also be able to do the same but the quiz comes up as preview for them.
I've tried enrolling them as both student and teacher but that doesn't do it either. Is there a way for a teacher to also complete the course in the same way that the students do?
It's not possible to allow a user to preview AND attempt quizzes. To enable the teacher to attempt the quiz, you need to modify the permissions (in the course or in the quiz) and allow mod/quiz:attempt and prevent mod/quiz:preview. Please see the documentation Permissions for more details.