Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

e-Mail Templates setup for all surveys

More
7 hours 55 minutes ago #274875 by wegszebe
Please help us help you and fill where relevant:
Your LimeSurvey version: 7.0.6
Own server or LimeSurvey hosting: own server
Survey theme/template:
==================
I can modify the e-Mail templates for a specific survey.

How can I setup / modify some e-Mail template to be used for all new surveys?

Thanks for Help
Regards
Karl-Heinz

Please Log in to join the conversation.

More
2 hours 6 minutes ago #274876 by Joffm
Hi,
general explanation:
These templates are hardcoded in "application/core/LsDefaultDataSets.php", line 800 ff.
Code:
            'admin_notification_subject' => gT("Response submission for survey {SURVEYNAME}", $mode),
            'admin_notification' => gT("Hello,\n\nA new response was submitted for your survey '{SURVEYNAME}'.\n\nClick the following link to see the individual response:\n{VIEWRESPONSEURL}\n\nClick the following link to edit the individual response:\n{EDITRESPONSEURL}\n\nView statistics by clicking here:\n{STATISTICSURL}", $mode),
            'confirmation_subject' => gT("Confirmation of your participation in our survey"),
            'confirmation' => gT("Dear {FIRSTNAME},\n\nThis email is to confirm that you have completed the survey titled {SURVEYNAME} and your response has been saved. Thank you for participating.\n\nIf you have any further questions about this email, please contact {ADMINNAME} on {ADMINEMAIL}.\n\nSincerely,\n\n{ADMINNAME}", $mode),
            'invitation_subject' => gT("Invitation to participate in a survey", $mode),
            'invitation' => gT("Dear {FIRSTNAME},\n\nYou have been invited to participate in a survey.\n\nThe survey is titled:\n\"{SURVEYNAME}\"\n\n\"{SURVEYDESCRIPTION}\"\n\nTo participate, please click on the link below.\n\nSincerely,\n\n{ADMINNAME} ({ADMINEMAIL})\n\n----------------------------------------------\nClick here to do the survey:\n{SURVEYURL}", $mode) . "\n\n" . gT("If you do not want to participate in this survey and don't want to receive any more invitations please click the following link:\n{OPTOUTURL}", $mode) . "\n\n" . gT("If you are blocklisted but want to participate in this survey and want to receive invitations please click the following link:\n{OPTINURL}", $mode),
            'reminder_subject' => gT("Reminder to participate in a survey", $mode),
            'reminder' => gT("Dear {FIRSTNAME},\n\nRecently we invited you to participate in a survey.\n\nWe note that you have not yet completed the survey, and wish to remind you that the survey is still available should you wish to take part.\n\nThe survey is titled:\n\"{SURVEYNAME}\"\n\n\"{SURVEYDESCRIPTION}\"\n\nTo participate, please click on the link below.\n\nSincerely,\n\n{ADMINNAME} ({ADMINEMAIL})\n\n----------------------------------------------\nClick here to do the survey:\n{SURVEYURL}", $mode) . "\n\n" . gT("If you do not want to participate in this survey and don't want to receive any more invitations please click the following link:\n{OPTOUTURL}", $mode),
            'registration_subject' => gT("Survey registration confirmation", $mode),
            'registration' => gT("Dear {FIRSTNAME},\n\nYou, or someone using your email address, have registered to participate in an online survey titled {SURVEYNAME}.\n\nTo complete this survey, click on the following URL:\n\n{SURVEYURL}\n\nIf you have any questions about this survey, or if you did not register to participate and believe this email is in error, please contact {ADMINNAME} at {ADMINEMAIL}.", $mode)

The function "gT()" is used to translate this into the active language.
Here a screenshot of the translation to German


Now you have two options:
1. If you are really absolutely sure that you will never create a multilingual survey:
Hard code the text in "LsDefaultDataSets.php" without any translation.

2. Create your own translation file.
  • Download the *.po-file
    [url] translate.limesurvey.org/projects/limesurvey-7/de/default/ [/url].
     
  • Install the tool Tool "poEdit.exe"  [url][/url] poedit.net/download
  • Adapt the translation to your needs
  • Save the file
    A  *.mo file should be created automatically; if not there is a button.
  • Upload this  *.mo file (de.mo) into the "locale"-folder , that refers to your language code, probably "locale/de".
BEWARE: Both this solutions are overwritten in an update. So you should save them somewhere.

And an observation:There seem to be no difference between "German" and "German(informal)".  In German there is also "Du". In my opinion a bug.

Joffm 
 

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose