Hello,
I tried what I could to disable the user confirmation after subscribing a newsletter. But I could not do it, so I'm keeping the confirmation emails. My problem is that the confirmation link in the emails is invalid and results in 404 - page not found.
After some trying and testing, I found out that any address like /newsletter results in the same error. What is missing in my site to enable this address to work? I have taxonomy installed and I can see the newsletter there.

thanks

Comments

sutharsan’s picture

Status: Active » Postponed (maintainer needs more info)

Please provide the confirmation link from the email.

nunodonato’s picture

sutharsan’s picture

I can see that something goes wrong with creating a subscription account (table: simplenews_subscriptions).
1. Check your error log for php errors
2. Check if records are added to simplenews_subscriptions table when a visitor subscribes to a newsletter. Each records must have an 'snid' NOT equal to zero.
3. If you can debug the simplenews_subscribe_user() function (in file: simplenews.module)

nunodonato’s picture

Ok, i'll try to check that.
but i do think the problem is something else, as I can not even access the /newsletter/ page. wasnt it supposed to give me a list of available newsletters? instead I only get a 404...

sutharsan’s picture

/newsletter does not give anything. It does not exist. Perhaps you confuse it with: /newsletter/subscriptions

ispace’s picture

Hi, i have the same problem, http://autoadviser.r00.ru/newsletter/confirm/add/10fb0288040t15 (Russian lang, error is Page not found).
I have simplenews_subscriptions table, it working alright, i see all pending subscribers.

sutharsan’s picture

Your newsletter block is called without tid parameter. Try the solution below.

@nunodonato: goto admin/build/block, (unset and) set the newsletter block in the right region and [Save]

sutharsan’s picture

Status: Postponed (maintainer needs more info) » Closed (fixed)

No response, closing the issue.

johanb’s picture

Status: Closed (fixed) » Postponed (maintainer needs more info)

It looks like this issue is still existing. I'm experiencing the same problem.

The "confirm link" results in a 404 message when an anonymous visitor subscribes to a newsletter.
Everything is working fine with logged in/registered users.

No php errors are triggered, only 404 errors.

"snid" is ok in the table "simplenews_subscriptions" with a valid int.

Only difference is a '0' in the column "uid".

sutharsan’s picture

uid 0 is normal for anonymous. Pls copy the unsubscription url here (or at least the last part of it)
The problem may be caused by access permission on the taxonomy. Do you have any access restriction (TAC, etc) in place?

johanb’s picture

I'm not using any TAC module.

Here is an example link, it's a subscription link: http://www.kwets.be/cms/newsletter/confirm/add/d55c668a6e0t19

Only module i think could mess things up is PathAuto (Pathauto 6.x-1.1), no?

Would it be an idea to add the option to disable the url aliasing for the subscription/confirmation links?

sutharsan’s picture

It can not be related to PathAuto, but this problem keeps popping up, but I can not reproduce it.
See #3 above

sutharsan’s picture

Status: Postponed (maintainer needs more info) » Needs review
StatusFileSize
new2.18 KB

Check if you have a user with uid = 0 in table 'user'. Try the attached patch, it solves the problem in this case.

johanb’s picture

Status: Needs review » Reviewed & tested by the community

Yes, this is it!

I didn't have a '0' ID anonymous user, don't know how that's possible though.

After applying the patch and testing subscribing, the link is working.
I now even got the "a mail is underway to confirm your subscription" message.

Thanks!

sutharsan’s picture

Status: Reviewed & tested by the community » Fixed

Nice isn't it ;) Patch committed.

sutharsan’s picture

StatusFileSize
new1.06 KB

I have found an other one with the same cause. Missing uid/0 causes only to list the subscribers with an account and not those without an account on the subscriptions admin page (admin/content/simplenews/users). That attached patch is committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

godspeed2048’s picture

Is this a duplicate issue?

http://drupal.org/node/331759

I'm having the same problem in Drupal v6.14

Odd thing, I had this problem where EVERY PAGE (including administration pages) returned a 404... (http://drupal.org/node/228462)... I was never able to solve this issue and decided instead to just re-install the entire website.

Then, after reinstalling Drupal and uploading all of the modules that I'd had before, I got this error on the Confirm Page (admin/build/modules/list/confirm) and occasionally on pages like Modules (admin/build/modules) or just Administration (admin).

There are two things that are really odd about this:

1) The problem is inconsistent, sometimes Drupal returns the page I want and sometimes it throws a 404

2) I haven't actually ENABLED any of the modules that I uploaded, only the "Core - optional" modules (all but syslog)... meaning that either:

A) Enabling one of these core modules caused the problem - putting the problem in the Drupal package

...or:

B) One of the modules that I uploaded was able to cause the problem even though it was never enabled

The only other thing that I can think of is that by altering .htaccess to increase the memory limit - or some other sort of server-setting related action on my part, I inadvertently caused the problem... But I think it's Drupal or a module.

Going to disable core modules one by one until the problem goes away and if I run out of those without fixing it, I will start deleting folders from the sites/all/modules directory. If I run out of those without fixing it, I'm going to go with an earlier version of Drupal and call it a day.

Let you know if I find anything.