• Resolved prog7

    (@prog7)


    Hello!
    I want to customize lesson template: /wp-content/plugins/sensei-lms/templates/globals/wrapper-start.php and /wp-content/plugins/sensei-lms/templates/globals/wrapper-end.php files.
    But it changes are erased.
    how can i change the template so that the edits are not erased on update?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi @prog7 ,

    You’ll need to override the templates. Basically, this involves copying the template to your theme directory – this prevents Sensei updates from removing any edits you’ve made.

    You can override any of the templates found in this folder by copying them to

    /yourthemefolder/sensei/

    and editing the files there. Sensei LMS will automatically load any template files you have in that folder, and use them instead of its default template files.

    We have more information here:

    https://senseilms.com/documentation/theming/

    Best,
    Cena

    • This reply was modified 3 years, 10 months ago by Cena (a11n).
    Thread Starter prog7

    (@prog7)

    Hello!
    The plugin folder is //wp-content/plugins/sensei-lms
    I have files
    /wp-content/themes/maxbizz-child/sensei/templates/globals/wrapper-start.php
    and
    /wp-content/themes/maxbizz-child/sensei-lms/templates/globals/wrapper-start.php

    I do not see on the site the changes that I made to these files
    Can you help please – how can i make changes to the lesson output template so that it doesn’t get chafed on updates?

    Hi @prog7 ,

    > I have files
    /wp-content/themes/maxbizz-child/sensei/templates/globals/wrapper-start.php

    We can’t really help with custom code like this due to our scope of support.

    That said, it looks like you’re not putting your edited template files in the correct directory.

    It looks like you’re doing something like this:
    /my-theme/sensei-lms/templates/global/my-file.php

    You have to put the files where Sensei knows where to find them, which is simply /my-theme/sensei.

    There are more details here: https://senseilms.com/documentation/theming/

    Best,
    Cena

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘custom teplates for lessons’ is closed to new replies.