Is it safe to edit Coursepress theme files?

When coursepress comes out with an update, will we lose any edits to the theme? I'm having to make a lot of customizations, so I need to make sure the changes will be secure into the future. If not, any insight into how to update Coursepress in the future to preserve any theme customizations is much appreciated. The plugin functionality itself is untouched, but we need to customize this theme in several areas in order to make it work for the current project.

  • Kasia Swiderska

    Hello Christian,

    If you change theme inside the CoursePress plugin then yes, you will loose all the changes after update.
    To prevent this you should create child theme for CoursePress theme https://codex.wordpress.org/Child_Themes and move your changes to child theme (also you need to copy CoursePress theme to wp-content/themes/ folder).
    This way you will be still able to update plugin and even update theme and all your changes will stay safe in child theme.

    kind regards,
    Kasia

  • Christian

    Thank you. I've created a child theme, and it seems to be running just fine. I have it installed in the normal wp-content/themes folder in the parent site, and I have it activated and running on the appropriate subsite on our multisite. All seems to be running great. Coursepress as a plugin remains where it was originally installed of course, and I've left the plugin folder completely alone.

    So my understanding is that with this configuration, we should be able to make any and all edits we want to the child theme, and we should be able to update coursepress plugin as it comes out with updates in the future, and it won't affect our theme at all.

    Additionally, when coursepress updates, it may be necessary to copy the "theme" folder inside the plugin over to our wp-content/themes folder and overwrite the parent theme, in order to keep the theme updated properly in addition to the plugin files.

    Does this all sound accurate? Am I missing anything? Much appreciated

  • Nithin

    Hi Christian,

    Glad to know you figured it out, and it does sound accurate. :slight_smile:

    Best way to make a modifications to a theme is to create a child theme, so that the tweaks made on a theme won't get overwritten when the theme is updated. As you have mentioned above, you can make numerous number of changes to your child theme, as well as update your parent theme and your plugin to the latest features available.

    Please let us know if you need any further help. Have a nice day. :slight_smile:

    Kind Regards,
    Nithin