12% off of LTD using this coupon: TWELVEPERCENTOFF. Promo ends on 2 Dec midnight UTC.
Published on Apr 29, 2020

How to override Tutor LMS’ templates using a custom functionality plugin

Sridhar Katakam

This members-only tutorial shows how tutor_get_template_path filter can be used to override Tutor's templates from a specific directory inside the My Custom functionality plugin.

This is especially useful when using Oxygen since Oxygen disables the active theme.

A member asked:

I would like to override 2 files from following directories:

1) wp-content/plugins/tutor/templates/dashboard/registration.php

2) wp-content/plugins/tutor/templates/dashboard/instructor/registration.php

dashboard/registration.php is used for the display of Student Registration page (https://example.com/student-registration/)


dashboard/instructor/registration.php is used for the display of Instructor Registration page (https://example.com/instructor-registration/).

We can extract the template name from the template location that Tutor supplies with the filter, append it to custom plugin's template path and return this new location to Tutor so it looks for each template in the custom plugin and use it if present or the one from Tutor if not.

Step 1

Install and activate My Custom Functionality plugin.

Connect to your hosting account using a FTP client and navigate to site's /wp-content/plugins/my-custom-functionality-master.

Edit plugin.php and add the following at the end:

This is a premium members-only content.

To view the rest of the content, please sign up for membership ($47/month or $599 one-time).

Already a member? Log in below or here.