Viewing 15 replies - 1 through 15 (of 17 total)
  • Thread Starter kellyrnh

    (@kellyrnh)

    Also, shortcodes don’t seem to work in the footer either. Any help is appreciated!

    Plugin Author Mike Walsh

    (@mpwalsh8)

    I am traveling this week and will look at this when I get back home. It may be a day or two.

    Plugin Author Mike Walsh

    (@mpwalsh8)

    I just had a chance to look at this question and now that I am doing it on my computer instead of my phone, I now understand what you’re asking for. What you are seeing the intended behavior of the plugin.

    Short codes are processed as part of the Post/Page notification email capability as part of the retrieval of the post content using the WordPress API. When sending an email to users or groups, there is no short code processing performed. Whatever content appears in the text box is simply used for the email content.

    I am not sure if there is any risk of processing shortcodes within an email or within the footer.

    Thread Starter kellyrnh

    (@kellyrnh)

    Thanks so much for getting back to me.

    I am looking to put generated coupons on the emails, and am using AdRotate to do this on the site, and was hoping to have them work together. Any idea on how I can do this?

    Thanks!

    Plugin Author Mike Walsh

    (@mpwalsh8)

    I think you could do what you want to do using the mailusers_html_wrapper filter which Email Users defines. There is an example usage of the filter included with the plugin.

    The filter allows you to modify both the message body and footer so I would think you could use it to add your coupons to the email by passing the appropriate arguments to do_shortcode().

    Because the filter expects the user to provide the HTML wrapper for the email you’d likely have to do something like the example does as well.

    knudoboy

    (@knudoboy)

    But if there is no short code processing done in the mail content, why are they used in the standard settings for mailtext?The shortcodes work in the header of the mail, (subject field) but not in the body of the mail.

    can I cure this?
    Mails appear like this:

    Hej

    Jeg vil g?re dig opm?rksom p? et nyt indl?g der er blevet publiseret p? bloggen. Detaljer omkring indl?gget f?lger; Jeg h?ber du finder det interessant.

    Venlig hilsen

    % FROM_NAME %

    % POST_TITLE %

    % POST_EXCERPT %

    Link til indl?g: % POST_URL %
    Link til % BLOG_NAME %: % BLOG_URL %

    Drevet af Email Users.

    knudoboy

    (@knudoboy)

    But if there is no short code processing done in the mail content, why are they used in the standard settings for mailtext?The shortcodes work in the header of the mail, (subject field) but not in the body of the mail.

    can I cure this?
    Mails appear like this:

    Hej

    Jeg vil g?re dig opm?rksom p? et nyt indl?g der er blevet publiseret p? bloggen. Detaljer omkring indl?gget f?lger; Jeg h?ber du finder det interessant.

    Venlig hilsen

    % FROM_NAME %

    % POST_TITLE %

    % POST_EXCERPT %

    Link til indl?g: % POST_URL %
    Link til % BLOG_NAME %: % BLOG_URL %

    Drevet af Email Users

    Plugin Author Mike Walsh

    (@mpwalsh8)

    I think you are confusing WordPress shortcodes and the keyword substitution which Email Users defines. They are very different.

    The keyword substitution should work in a regular email. From what you show above you have spaces between the percent character (%) and the keyword. Can you verify that your email content has it like this:

    %FROM_NAME%

    and not like this:

    % FROM_NAME %

    If you have spaces it will not work as the pattern match will fail.

    knudoboy

    (@knudoboy)

    Thank you for swift reply. You are right, there were spaces. But I did not put them there. I just clicked standard settings, and the shortcodes appeared in the mail template. So you may want to update something in the files, I presume.

    Things work fine now. I have a multisite, so its quite a job to remove all the spaces. Is there an easier way?

    knudoboy

    (@knudoboy)

    No worry. I just fixed it copypaste..

    Plugin Author Mike Walsh

    (@mpwalsh8)

    Glad to hear it is working for you. I was going to say I am not sure what settings I could change because there isn’t anything which automatically adds the fields to an email or post. There is the default notification template but that is for posts/pages only.

    knudoboy

    (@knudoboy)

    Here are some dumps from the settings page, where I can set the notification mail to a template or standard with one click. I hope you get the point.

    https://www.haugmark.dk/gymnasieniveau/settings-screendumps/

    Plugin Author Mike Walsh

    (@mpwalsh8)

    Where does the image in the first screen grab come from? That is not a page from Email Users.

    knudoboy

    (@knudoboy)

    Oh yes they are all from email users.
    Check the footer text, where it says “email users”

    But the publish button in the post edit window has gone away. I can make pages still, but no posts. Email users has not been tested on my version of wp. maybe thats why. I must fint out.

    Plugin Author Mike Walsh

    (@mpwalsh8)

    That seems odd. The only change Email Users makes to the Post screen is to add the “Notify Users of this Post” box on the upper right hand corner. It doesn’t do anything to the post editing content itself. It almost sounds like the page isn’t fully loading or getting an error during load which results in an incomplete page.

Viewing 15 replies - 1 through 15 (of 17 total)
  • The topic ‘Process shortcodes in manual emails?’ is closed to new replies.