Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Shawn Calvert 31 posts 192 karma points
    Aug 22, 2018 @ 14:35
    Shawn Calvert

    Modify Newsletter Studio template based on member properties

    Hi Markus

    We just purchased Newsletter Studio, and it's working great. I have a question on the feasibility of something we would like to do, or how you would suggest handling setting it up.

    scenario: We have a list of members who have member properties indicating what newsletters they subscribe to, and what format they want to receive the email in (html email, a link to a pdf, or an attached pdf). There are 4 newsletters, all with the 3 different email type options.

    The painful way would be to create separate templates and member groups for each variation, with the editor having to send out 12 emails every week. yikes

    I'm assuming the right way would be to set up a member group for each newsletter, and use render tasks to get the member properties into conditionals in the template, that would modify the email template per member.

    Before we go too far down the road, is that possible with render tasks, or is there some other approach that would be better?

    thank you

  • Markus Johansson 1654 posts 4674 karma points c-trib
    Aug 23, 2018 @ 07:42
    Markus Johansson

    Hi Shawn!

    Thanks a lot for using the package!

    I think/hope that I understand what you are trying to do =D

    You could put a render task somewhere in the end of the chain and using this, depending on the members choice of html, link or pdf take the actions that you need.

    Are you sending from the backoffice or are you using the content-section? I'm thinking that if you are using the content-section you could have a Document Type for the newsletter node that has properties for each senario

    1. HTML: Maybe a richtext editor (RTE)
    2. Link to PDF: Maybe a RTE with a placeholder for the link or a textarea
    3. PDF Attachment: A file-upload or media picker to choose the PDF file and maybe some simple RTE/Textarea for a "intro text" or something

    Then in the render task you could do something link

    • HTML: Keep the current content from the rich text editor
    • Link to PDF: Wipe the content and insert the content from the special RTE/Textarea, replacing your placeholder with the URL to the PDF
    • PDF Attachment: Wipe the content, use the "MailMessage"-class that is passed to the render task to attach the file.

    As far as I can tell you should be able to do all of this using the render task, but you might want to think about the order in which you execute the task since if you put your custom task last in the chain and wipe the content you will lose the click tracking etc.

  • Shawn Calvert 31 posts 192 karma points
    Aug 27, 2018 @ 20:58
    Shawn Calvert

    Thanks Markus, this set us on the right direction!

  • Markus Johansson 1654 posts 4674 karma points c-trib
    Aug 28, 2018 @ 07:38
    Markus Johansson

    Great! =D Just let me know if you have any questions or feedback! I'm all open to include improvements if the current version can't meet your requirements.


Please Sign in or register to post replies

Write your reply to: