WordPress.org

Ready to get started?Download WordPress

Forums

Follow
How does a subscribed user unsubscribe or unfollow? (6 posts)

  1. an_ngo
    Member
    Posted 2 years ago #

    How does a subscribed user unsubscribe or unfollow?

    http://wordpress.org/extend/plugins/follow/

  2. NoProbRob911
    Member
    Posted 1 year ago #

    I am not the developer, nor do I have any relationship with him/her/them. But after looking through the plugin source code, I do have at least a PARTIAL answer to your question:

    In the confirmation email, there is a link to click to confirm the subscription. That link includes ?s2=1xxxxxxx where xxxxxxx is a unique identifier for that subscriber. According to the code, if you change the ?s2=1 to ?s2=0 it becomes an UNsubscribe link. I have not actually tested that, but it appears to work.

    "Best practices" -- and compliance with the US CAN-SPAM Act -- suggests including a "Click here to unsubscribe..." link with that ?s2=0xxxxxx link.

    Note: I am using version 10.0.3 because later versions introduced an incompatibility with the "Exclude Pages" plugin. (It appears that the author tried to implement that same feature in this plugin and simply lifted the code from that plugin. That would have been fine IF he had at least changed the function names to avoid the conflict. IMHO, this program author should have just referred his users to that plugin instead of trying to incorporate it into his.) If you are using a different version of this plugin, all bets are off regarding my comments here.

    I would really like to be able to use this plugin. (JetPack slowed my page load times by as much as 20 seconds on some occasions when there were communication issues with WP.com -- unacceptable!) But since this plugin author seems to be MIA, and there are some features that are either missing completely or just don't work "right," for now I have to consider this plugin "broken." But I think it has potential, so at some point I will delve deeper into the code to see if I can fix some of the issues. I'll either post my fixes or spin-off a new plugin based on this one incorporating those fixes.

    Hope this helps.

  3. emcarnahan756
    Member
    Posted 1 year ago #

    @NoProbRob911

    I would love if this plugin included an unsubscribe link in every email. The best workaround I can think of is to alter the welcome note via options to send an email if you want to be unsubscribed -clumsy, but a possibility... Seeing as how there seem to be no other options at present, judging from a series of searches..

    If you do look at the code to this end and/or develop a spin-off, please do post a reply comment here so we know about it, or contact me via my personal blog if they have closed this to comments by then —

    Many thanks for your interest. Ellen

  4. NoProbRob911
    Member
    Posted 1 year ago #

    @emcarnahan756

    This was sort of a low priority item for me, and slipped my mind. But being notified of your comment helped spark my memory. Thanks for that.

    After briefly revisiting this issue, I realize now that if you go to the subscribe page (that you are required to create for use by this plugin), you are given a subscribe/unsubscribe option there -- UNLESS you are currently logged-in to your site, in which case you are referred to modify your subscription under your user profile settings. Don't know how I missed that before. (Probably because I logged in to look at what the plugin was doing and got the referral to the profile page instead. Oops! Should have logged out and looked again. A "senior moment," I guess...)

    The unsubscribe feature on the subscribe page does work. And it does email a confirmation request for the unsubscription, which is as it should be to prevent others from unsubscribing you.

    So ... you could modify the subscribe confirmation email to inform the subscriber to visit the subscribe page to UNsubscribe, which I realize is counterintuitive. Like clicking the Start button to end Windows, I guess... ;-)

    Again, I'm using v 10.0.3 of this plugin with WP 3.5.1, so "your mileage may vary" with different versions of either.

    I still think there ought to be an "unsubscribe" link in the actual emails, and it wouldn't really be that difficult to add that capability. All that would be needed would be to find the code that sends the emails and add the unsubscribe link, grabbing the subscriber's unique ID (that subscribe/unsubscribe confirmation number) from the subscriber database. Obviously, this would not work if the emails were sent bulk rather than individually. I did not spend enough time today to follow up on that idea, but this plugin's "Restrict the number of recipients per email to (0 for unlimited):" setting might apply here.

    At the very least, IMHO, an automated unsbuscribe link (using that ?s2=0 thing I mentioned previously) ought to be in the original subscription confirmation email with a suggestion that they save that link should they change their mind and want to unsubscribe.

    But right now I still consider this a "back-burner" item for me. As soon as they add that 8th day to the week, I might try to spin-off a new version of this plugin, properly providing the unsubscribe link and eliminating the incompatibility with the Exclude Pages plugin. If I ever get to that, I'll update here, or you can search for my username here on WP.

    For now, I suggest you just modify the plugin's email template to refer them to that subscribe page. Good luck!

  5. emcarnahan756
    Member
    Posted 1 year ago #

    Hi NoProbRob
    Wow, thanks for all the info! One further complicating issue for me was that I couldn't get Subscribe2 to activate without fatal error -I see a few people posting that kind of problem, so I am now looking at other plugins rather than try to solve something that seems at least partly broken.

    I do like the follow button graphically, it is very smooth looking on all the sites I've seen it -I may just use the pop form/css and write it to redirect to my MailChimp or Wysija signin. . .

    Thanks though for all this -I will bookmark it in any case
    E :)

  6. NoProbRob911
    Member
    Posted 1 year ago #

    @emcarnahan756

    You mentioned using the pop form/css with another maillist handler. That's actually a great idea™. You could easily use his pop form/css stuff and just have his form submit to whatever form your preferred maillist handler uses for signups. This would work like a cross-site scripting attack, except it wouldn't be cross-site so there should be no firewall issues or anything.

    Another option: You could have his follow button CSS just pop up that other maillist form directly in an iframe in a FancyBox. (Kinda yucky, but ehhh...)

    For those who are less into code™ and want to make this plugin work, I offer the following:

    Eliminate (deactivate and uninstall) the Subscribe2 and Exclude Pages plugins and try again. If you still get fatal errors, step back to the next older version of this plugin (from the developer's page) and try again. Repeat disabling conflicting plugins and trying older versions until you get a combination that works. Then decide if you can live without those other plugins, or with this guy's outdated recreations of them.

    PROBLEM: The fatal error is most likely a redeclaration/redefinition problem.

    REASON: It appears the plugin author tried to incorporate other plugins into this plugin, apparently by copy-and-paste (which is fine under GPL, by the way). Trouble is, he kept the same function names, etc., so that creates a conflict if you try to use the other plugin. He did this with the Subscribe2 and Exclude Pages plugins; possibly others. Theoretically, those plugins' functionality is in this plugin, but ...

    There are advantages and disadvantages to what the author did. Advantage: Something this plugin requires is guaranteed to be there if it is included as part of this plugin itself. Disadvantages: (1) If the other plugin is updated, say to fix a security issue or to add a wonderful new feature, this plugin does not automatically get the same fix unless this author updates this plugin (again, via cut-and-paste). Since this author appears to be MIA, don't hold yer breath... (2) As we've already seen, if you already have that other plugin, this plugin creates a fatal redeclaration error since both plugins are creating functions, classes, etc., with the same names.

    Better option: The author should have either renamed the functions, classes, etc., that he grabbed from other plugins, OR he should have checked for those required plugins (using WP's is_plugin_active function upon activation of this plugin and either informed the admin that those are required OR used his cut-and-pasted versions (again, taking advantage of the is_plugin_active function). Pseudo code:

    on plugin activation
        if required function/class does not exist
          inform admin what other plugins are required
          do not activate this plugin

    OR

    on plugin activation
        if required function/class does not exist
          include my code to create my own versions of that stuff
          continue activation and setup of this plugin

    FIX: Here is what is working for me:

    • I already had the Exclude Pages plugin installed and active, so I went back to a version of this plugin prior to him trying to incorporate that one. The version I am using is 10.0.3, which is available on the plugin developer's page.
    • I am not using the Subscribe2 plugin, as this plugin includes that functionality (at least in version 10.0.3).
    • I edited the plugin's main file (follow.php) to change the version number to 999.99 so that I don't get constantly notified of updates that I know for a fact do not work (at least on my setup) and run the risk of accidentally updating it.
    • I modified the email templates to direct subscribers to www.example.com/subscribe/ to unsubscribe.

    I have a lot of security on my sites. Any plugins which have as many issues as this one concern me, but I'm reasonably comfortable using this as described here. (But I am keeping close tabs on the thing.)

    I suspect that if you grabbed a later version of this plugin and just avoided installing/activating Subscribe2 and Exclude Pages (and any other plugins that caused fatal redeclaration errors), this plugin would probably work. But I have not tested that.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic