• Resolved stijndn

    (@stijndn)


    Hi Franky,

    Thanks a lot for the plugin.
    I also use contact form 7. If someone check the newsletter checkbox in the contact form 7, I would like that the information is updated in eme. This works.
    The only thing I don’t know how to do is to trigger the newsletter confirmation mail with php if I have the person_id?
    Could you help with this?

    Greetings
    Stijn

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Franky

    (@liedekef)

    Check the function eme_sub_send_mail in eme_people.php
    It takes as arguments lastname, firstname, email and the groups to subscribe to (an array of group id’s)

    Thread Starter stijndn

    (@stijndn)

    Thanks Franky,

    It works to send the confirmation newsletter email. But the subscribe link is not active anymore. How can I make this work.
    Do I need to create an active link, or how does this work?

    Plugin Author Franky

    (@liedekef)

    The url needs to be generated (see also that function).
    But the url uses a WordPress nonce, meaning it takes the user id into account the moment the nonce gets generated. So if you’re logged in at the moment of subscription, the nonce is also only valid when being logged in (and thus the confirmation url too). The same goes for not being logged in at the moment of subscription.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘send newsletter confirmation mail with php’ is closed to new replies.