Save template as a core template

More
5 months 1 week ago #154951 by blocka
blocka created the topic: Save template as a core template
After I've customized a template, I'd like to add it to /templates/ so that people can copy it to modify themselves (and can't delete it). But when I place my template in the /templates directory, it doesn't appear in the template editor.

If I place it in the /upload/templates/ folder of course it does, but then people who have permissions to manage templates can delete it.

I'm using the latest version of LS 2.65.0 (170502)

Any advice?

Please Log in to join the conversation.

More
5 months 6 days ago - 5 months 6 days ago #154958 by LouisGac
LouisGac replied the topic: Save template as a core template
For now you should hack the core code to add your template to standard templates:
github.com/LimeSurvey/LimeSurvey/blob/ma...ls/Template.php#L280

We're about to do a new release this week. I will modify the code so the list of standard templates will come from the configuration file (so you can modify it without hacking the code).
Last Edit: 5 months 6 days ago by LouisGac.
The following user(s) said Thank You: Ben_V

Please Log in to join the conversation.

More
5 months 6 days ago #154986 by blocka
blocka replied the topic: Save template as a core template
Excellent! Thanks for including that in the next release :-)

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now