Home Forums Newsletter Plugin Support Subscription success message via ajax… possible?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #161291
    oloccina
    Participant

    Hello,
    I just installed the plugin and I am testing the subscription form using a popup here https://nican.me/new/blog/ (see “subscribe via email” link in the site header below the word “Blog”)

    The form works fine, though an issue is that it redirects to a “success” page after the subscription. Instead, I want it to just save the new subscriber without closing the popup or redirecting to a new page.
    Do you think there could be an easy workaround for this? Maybe some setting I am still missing in the configs?

    Thank you

    #161325
    Stefano
    Keymaster

    You should recode the form to call the action na=ajaxsub instaled of na=s as action parameter (and manage the ajax submission).

    Stefano.

    #161470
    oloccina
    Participant

    Thank you.
    I have now this custom form

    <div class="tnp tnp-subscription">
    <form method="post" action="https://nican.me/new/?na=ajaxsub" onsubmit="return newsletter_check(this)">
    
    <input type="hidden" name="nlang" value="">
    <div class="tnp-field tnp-field-email"><label>Email</label><input class="tnp-email" type="email" name="ne" required></div>
    <div class="tnp-field tnp-field-privacy"><label><input type="checkbox" name="ny" required class="tnp-privacy"> <a target="_blank" href="https://nican.me/privacy">I accept the privacy policy</a></label></div>
    <div class="tnp-field tnp-field-button"><input class="tnp-submit" type="submit" value="Subscribe">
    </div>
    </form>
    </div>

    Could you suggest what else I need to edit there in order for the ajax subit to work correctly?
    Right now is just redirecting to this page: https://nican.me/new/?na=ajaxsub
    I am not a developer but I can edit basic code.

    Thanks

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.