Problems with Newsletter sign-up in Pop Up!

Hi, I have some questions about getting the newsletter sign-up form working correctly within a pop-up.

However, first I am trying to have the pop up appear on only a single page on my site so I can test it out with you. But I can't get this to work. I placed the full URL of the target page (with http:// ) under the "On Specific URL" condition.

The only other condition set is the user must be logged in (currently I am the only user). If I don't have this user condition set, the pop-up appears on every page.

Here's the link to the page the pop up is supposed to show up on. I am logged in and don't see it. http://bit.ly/LawcHE

  • ThePath
    • The Bug Hunter

    Hi Mark,

    Well this is a plugin I havent used so not sure if I can be a massive help, however I checked your site in Firebug and found the folowing:

    "NetworkError: 404 Not Found - http://floatation.biz/wp-content/plugins/custompress/datepicker/js/i18n/jquery.ui.datepicker-.js?ver=1.8.18"

    The "fb-root" div has not been created, auto-creating

    I doubt they will be related to be honest.

    But when I visit that page I dont see the popup which is what you want as Im not a member.

    I wonder if one of the support guys can jump in here with some advice if they have seen it before and can answer quickly. Otherwise I can set this up on a test site to see if I can replicate it.

    I see from the instructions: https://premium.wpmudev.org/project/the-pop-over-plugin/

    That you can set it to appear from other sources and conditions. Have you fiddled with these to see if the popup works with these other settings. If it doesnt then perhaps something has got messed up with install or a JS conflict somewhere. If it does then we can narrow it down to that specific scenario not working and look further.

    :slight_smile:

  • Kimberly
    • Champion of Loops

    mark77210

    Hi there! I did a quick test install and set the "on specific url" condition to a specific page on my site and it worked out fine.

    What other settings are you using? Please note that the settings are not mutually exclusive. They will both occur at the same time, but not take each other into consideration and will operate independently

    Perhaps a screenshot? Or if you want to remove the logged in testing setting I can see if I can see your pop up on the page you are referring to.

    Best,

    Kimberly

  • Mark
    • The Incredible Code Injector

    @ Kimberly

    Attached is the screenshot of the settings page. No special settings such as Javascript. I also removed the logged in setting and pop up is not showing up on the designated page (or any other page, which is a change).

    @ ThePath

    Thanks for taking a look. I also doubt that the two are related but I will take a look at what the deal is with the CustomPress js. Cheers..

  • Kimberly
    • Champion of Loops

    Mark,

    You should try to add a forward slash to your url.

    i.e. pop-over-newsletter-test/

    I tested with and without on my sandbox site and only got the popup when the slash was there. I usually copy/paste my url instead of typing out to account for things like this as well as spaces in the slug.

    Let me know if that works!

    Best,

    Kimberly

  • Mark
    • The Incredible Code Injector

    Hi Kimberly, thanks that worked. I originally did cut and paste but the URL doesn't have a fwd slash so none carried over.

    So here's Part 2 of the problem:
    I embedded the code for the newsletter sign up inside the pop up. I used the same code that is in the widget but made a few styling tweaks. You should be able to view the code using Firebug or whatever.

    Currently, when I enter an email address and click Subscribe, nothing happens. No form action engages. Is there an interference if a newsletter widget is on the same page? Did you try signing up using the pop up and did it work for you? Note: I am attempting to subscribe as a non-user, i.e. not logged in.

  • Mark
    • The Incredible Code Injector

    It works when widget is disabled but the thing is I need them to happily coexist. Any thoughts on how to do this?

    One other issue: When using the pop-up, no message appears after the person clicks submit. Is there a way to let them know on the spot that they've been successfully subscribed?

  • Mark
    • The Incredible Code Injector

    Hi Kimberly, have you heard anything back on this? It's been a week :slight_frown:

    Status update: Currently I have the newsletter widget turned off on all pages except one (the contact page) and I have the pop over set to appear one time. I'd really like to be able to have the widget and popover (with newsletter sign up inside) appear together. Thanks...

  • Kimberly
    • Champion of Loops

    Mark, very sorry for the delay here !

    My response feed plays tricks on me some days and I have been in and out for a family issue the last couple of weeks, bad combination for followup here I'm afraid.

    I will be flagging the developer Asap to see if there is any way we can have this coexist.

    I'm logging into my sandbox site to test now!

  • Mark
    • The Incredible Code Injector

    Hi Kimberly, no worries and hope all is okay within your family. Thanks for checking back in with me.

    I used the form code in the newsletter widget itself. I just lifted it using Firebug and pasted it in the popover.

    Code from widget:

    <form action="" method="post" name="subscribes_form" id="subscribes_form">
                <input type="hidden" name="newsletter_action" id="newsletter_action" value="">
                                <div>
                        <label for="e_newsletter_email">Your Email:</label>
                        <input type="text" name="e_newsletter_email" id="e_newsletter_email">
                    </div>
    
                                    <div>
                        <input type="button" id="new_subscribe" value="Subscribe">
                    </div>
    
                        </form>

    Final code in popover (includes some tweaks):

    <form id="subscribes_form" action="" method="post" name="subscribes_form"><input id="newsletter_action" type="hidden" name="newsletter_action" value="" />
    <div style="padding: 10px 5px 2px 10px;">
    <h5><input id="e_newsletter_email" type="text" name="e_newsletter_email" /></h5>
    </div>
    <div style="padding: 10px 5px 2px 10px;"><input id="new_subscribe" style="height: 2em; width: 10em;" type="button" value="Subscribe" /></div>
    </form>
  • Kimberly
    • Champion of Loops

    okay, doing some digging and it seem that what you copied was indeed the form, however, it's just that, the form. The action of submitting in the actual widget is tied to a function called "add member" in the e-newsletter php file.

    I was able to see a response when subscribing in the popover. However I saw the response in the widget area on the side, not in the popover. And I was only able to see the response when I tried to sign up with an email I already used, or when I clicked submit without an email in the box. A new email would not show anything for me.

  • Mark
    • The Incredible Code Injector

    Hi Kimberly,

    Yes, this just shows I don't really know what I'm doing. :slight_smile: I'm just sort of finding my way through the dark.

    Is there something I can do to make this work? Sorry, I didn't derive a solution from what you pointed out. Do I need to include that code in the popover plugin or ...?

  • Paul
    • The Green Incsub

    I see the issue. Or at least one issue. Working on some code for you. Part of the issue is when you copied the widget code the element IDs for the subscribe button, input field and form wrapper are no longer unique. Will write back in a few.

  • Paul
    • The Green Incsub

    I can get you a little down the road. I had to add the form plus JavaScript into the popup content https://gist.github.com/2960696

    In my implementation http://site4.media-tags.com/ the popup show. I fill in the email address, click submit. The page refreshes. Then I see the popup again. And I noted in the sidebar where the signup widget lives I see the message 'You are subscribed successfully! '

    That being stated I don't this will meet 100% of your needs. My assumption is you want some conditional logic for example to submit the subscribe form from within the popup and display the thank you message also within the popup. Plus my assumption is if the user has already subscribed there needs to be a way to not show the popup.

  • Mark
    • The Incredible Code Injector

    Hi Paul, thanks very much for your attention to this and following up after the Live Support session. I really appreciate it.

    I think you're right, though. It's not going to work unless the success message shows up in the popup and there needs to be a way for it to disappear once someone subscribed.

    I would mark this resolved but I don't see the Resolved check box.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.