Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

where can I change the welcome email in the newsletter


Go to End


6 Posts   1326 Views

Avatar
irmen

Community Member, 11 Posts

20 August 2014 at 11:11pm

Hi, I can't find,
where I can change the email, that is sent to new subscribers in my newsletter module.

Can you please help me, here I can find the template for it, that I can change it a bit.

Thank you so much!!
Irmen

Avatar
irmen

Community Member, 11 Posts

25 August 2014 at 7:07pm

Does really nobody know that?
Or is my question incomprehensible?

I'm looking for the "template" for the welcome Email, thatis sent, if a new subscriber ordered the newsletter.
I have to change it a bit.

Thank you very much for helping me to find the script!
Irmen

Avatar
martimiz

Forum Moderator, 1391 Posts

25 August 2014 at 10:05pm

Assuming you are using the silverstripe-newsletter module, that would be in newsletter/templates/email/SubscriptionEmail.ss

Note: after changing an Email template be sure to do a ?flush=all to renew the template cache.

Note2: be aware that if you change core templates, all changes will be lost when you update the module. You may add a custom SubscriptionEmail.ss template to your theme, that should override the module template

Avatar
irmen

Community Member, 11 Posts

25 August 2014 at 10:39pm

Thank you!! I got it!
Irmen

Avatar
irmen

Community Member, 11 Posts

25 August 2014 at 11:01pm

I happily found the emailtemplate but now I have another question.
In the subscriber confirm-email:

If I write
<p>Hallo $FirstName,</p> ...
it works.
But if I write
<p>Hallo $FirstName $Surname,</p> ... or <p>Hallo $Surname,</p> ... or <p>Hallo $FirstName $SurName,</p> ...
it doesn't work.
What can be the mistake?

Thank you very much! Irmen

Avatar
martimiz

Forum Moderator, 1391 Posts

26 August 2014 at 3:15am

$Surname should work...

Make sure you do a ?flush=all everytime you change the template. It's a bit of a hssle, but email templates aren't directly connected to the current Page controller, so SilverStripe won't automatically pick up the changes...

Often I just enter all variables first, do a flush=all and check if they are picked up before doing to much layout. Also, if things aren't picked up, try to add some static content like ***** to see if it's a refresh problem or e variable issue...