Support » Plugin: Post Notif » Confirmation link get a 404

  • Hi,
    first of all, thanks for developing this plugin!

    I read the previous posts about 404 error and double checked everything about it:
    -the .htaccess

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    -the permanentlink settings
    [o] Post name http://www.aliceayel.com/sample-post/

    -the link that I get after asking subscription is like this:
    http://www.thewplink.dom/post_notif/confirm?email_addr=name@mail.dom&authcode=xxxXxXxxx

    and finally got: “Oops! That page can’t be found.”

    I removed one by one, the other plugins, same result.
    I also tried with the default theme “Twenty Seventeen”, not better!

    It’s a bit mysterious there πŸ™‚
    Any idea will be appreciated!

Viewing 15 replies - 1 through 15 (of 20 total)
  • Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi benbois,

    Thanks for trying out Post Notif.

    I’m sorry to hear you’re running into “page not found” issues; that is certainly annoying!

    I appreciate you reading through the previous posts and providing your .htaccess, which looks good.

    I checked out your blog (http://www.aliceayel.com) and it doesn’t look like you have the Post Notif widget active at the moment, otherwise I’d subscribe and take a look myself. One thing you can try is replacing “/post_notif/confirm?email_addr=name@mail.dom&authcode=xxxXxXxxx” with “/post_notif/confirm/?email_addr=name@mail.dom&authcode=xxxXxXxxx” (the only difference is the addition of the “/” immediately following “confirm”) to see if you get a different result (other than the “page not found” error).

    It is helpful to know that you tested this with Twenty Seventeen and with all other plugins disabled, as this makes it clear, in my mind, that you are dealing with a URL configuration/routing issue of some sort and not something else.

    Thanks,
    Devon

    Hi Devon,

    Thanks for your quick reply.
    You’re right, I have disabled the Post Notif widget, I don’t want to provide a 404 link πŸ˜‰

    I tested the modified link (with a slash before the ? symbol -…/confirm/?email_addr=…), I got the same result – 404 page.

    Strange isn’t it?

    Cheers

    Ben

    Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi Ben,

    Hmmm, that IS strange.

    Do you see your test subscriber when you go to Post Notif >> Manage Subscribers in the dashboard? If so, does it show as confirmed? I ask because I’m wondering where the root of the failure is; on creation of the subscriber in the database or on (attempted) confirmation.

    Thanks,
    Devon

    Hi Devon,

    nothing in the admin tabs, none sucrisber is there (I made 3 subscriptions test).
    I checked the database, I have 5 tables refering to Post Notif:
    – post_notif_postHide
    – post_notif_subscriber
    – post_notif_subscriber_stage
    – post_notif_sub_cat
    – post_notif_sub_cat_stage

    All empty!

    Cheers,

    Ben

    Another thing, when I try to subscribe (with the widget’s form), after clicking on the subscribe button, the message is stuck on “Processing…” message.
    Nothing happens after that.
    I don’t know if it helps you.

    Cheers,

    Ben

    PS. I reinstalled the plugin, I got the same problem.

    Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi Ben,

    Thanks for the additional info. It sure sounds like the plugin is failing to create the subscriber rows (which get stored in the post_notif_subscriber table) which would explain you seeing nothing via the admin views (e.g., “View Subscribers”, “Manage Subscribers”, etc.). Additionally, the fact that the “Processing…” message (intended to be displayed only while a subscriber is being created via widget submission) never goes away makes me think that you may be having some sort of database permission issue, for the tables created during the plugin install, that causes a failure of the overall process which, in turn, aborts the AJAX that eventually replaces the “Processing…” message with your “widget success message”.

    Reviewing the code, I do see where I’m missing a check for successful subscriber creation (which is why you are still receiving the confirmation emails); that is definitely a bug I will address in the next release. Unfortunately, that alone will not resolve your situation (it would just make it clearer that you had a problem in the first place).

    If you sign into the database via a tool (like phpMyAdmin or something equivalent), using your WordPress site’s credentials (i.e., from wp-config) are you able to manually insert a row into the post_notif_subscriber table? And, one more question – is your site multisite?

    Thanks for sticking with this,
    Devon

    Hi Devon,

    I’ll try ASAP to insert data manually in the table.
    No, the website is NOT multisite.
    Cheers,

    Ben

    benbois

    (@benbois)

    Hi Devon,

    I tested to insert data in the tables plugin from the WP DB account with success!
    So, it is not the problem apparently.
    Just to add, I have a table prefix installed, could it be the problem?

    Cheers

    Ben

    Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi Ben,

    Thanks for trying that out and confirming that your DB user account does have permission to populate the tables that were created by Post Notif.

    It certainly could be the table prefix, though Post Notif’s code uses the $prefix property, in the core wpdb class, to generate SQL statements to operate on the plugin’s tables in your database, so it should work.

    Do you have other plugins installed, that create their own tables (resulting in the same prefix as the Post Notif custom tables), and are working fine? If so, would you please send me the name of one or more of those plugins so I can take a look at their code?

    Thanks,
    Devon

    benbois

    (@benbois)

    Hi Devon,

    WP Statistics (https://wordpress.org/plugins/wp-statistics/) is installed, it uses its tables and it’s working well.
    For info, the Post Notif tables have been created with the right prefix.

    Cheers,

    Ben

    • This reply was modified 3 years ago by benbois.
    Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi Ben,

    OK, thanks – I will take a look at DB code for WP Statistics and see what I can find. And thank you for confirming that the Post Notif tables have the same prefix as those created by WP Statistics.

    Thanks,
    Devon

    Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi Ben,

    I took a look at the WP Statistics plugin’s code and it appears to be handling prefixing of its custom tables identically to how Post Notif does. So I’m shifting focus to considering JavaScript/AJAX-related issues.

    If you still have the subscriber row (which you manually created) in the [prefix]_post_notif_subscriber table, what happens when you attempt to re-subscribe that same email address (via the widget)? Do you get any other message or does it still hang with “Processing…”?

    How about if you input a blank email address into the widget and hit the “Subscribe” button?

    Thanks,
    Devon

    benbois

    (@benbois)

    Hi Devon,

    when I try to subscribe with same email, I got this message:
    “You’re already subscribed so no need to do anything further.”
    So, it seems to work here.

    Cheers,

    Ben

    Plugin Author Devon Ostendorf

    (@devonostendorf)

    Hi Ben,

    Thanks for that additional data. That makes me think AJAX is working and it must be something directly related to the attempt to insert the new subscriber row into the table (and that its failure prevents the update of the “Processing…” message), though, curiously, it still sends the confirmation email to the subscriber.

    I have to admit that I’m presently stumped as to the root cause of the issue.

    As I mentioned above, I am going to add the missing check for (un)successful subscriber creation to the next version of Post Notif. Perhaps that will make it clearer as to why this is occurring. Once I have this in place, I will send you a pre-release version if you’d like to try it out and see if it reveals anything helpful for your situation.

    I’m sorry we’ve not been able to get to the bottom of this..

    Thanks,
    Devon

    benbois

    (@benbois)

    Hi Devon,

    It is OKAY, I will test your pre-release right I get it.

    Cheers

    Ben

Viewing 15 replies - 1 through 15 (of 20 total)
  • The topic ‘Confirmation link get a 404’ is closed to new replies.