The addition of i18n functionality in simplenews (http://drupal.org/node/270082) enabled registered users to receive newsletters in their preferred language.
The attached patch add this possibility for anonymous users. With one difference that anonymous users can not select or change the language of their preference. They are subscribed to a language based on the site language of the page they subscribe to. For example when they subscribe at example.org/fr/newsletter/subscriptions there preferred language will be French. When they subscribe at example.org/newsletter/subscriptions there preferred language will be the site's default language.
Comment | File | Size | Author |
---|---|---|---|
#5 | simplenews_languagechooser.patch | 3.05 KB | broon |
simplenews.anon_lang.patch | 10.74 KB | Sutharsan | |
Comments
Comment #1
Anonymous (not verified) CreditAttribution: Anonymous commentedAutomatically closed -- issue fixed for two weeks with no activity.
Comment #2
milos1234 CreditAttribution: milos1234 commenteddoes this patch work for the latest version?
thanks
Comment #3
Sutharsan CreditAttribution: Sutharsan commentedyes, it's included.
Comment #4
-Anti- CreditAttribution: -Anti- commentedIs this capability still a patch, or is it now included in the simplenews module as a feature?
Thanks.
Comment #5
broonI am maintaining several multi-lingual sites and I was missing the functionality mentioned above in 2.x branch. So I made a small patch which retrieves enabled languages and displays a language chooser in simplenews block.
Cheers,
Paul
Comment #6
miro_dietikerWe try to avoid cluttering the interface. We even removed other form parts recently.
There might be pages that don't care about preferred languages of users where display of the language selector is wrong.
It is also currently impossible to edit the language preference for anonymous subscribers. (The issue extends then to self-management of anonymous subscribers)
Note that for regular users, their user preferred interface language is taken into consideration.
If we open this discussion, we should work on a more complete solution and reconsider multilingual management.
Comment #7
broonI understand your intention to avoid to many form elements. So maybe an admin option to dis/enable a language chooser would be a solution?
As for the change of language for already subscribed "newsletter users" (anonynmous) I'm working on a solution right now. Anonymous user just have to enter their email address and select a new language. My patched version of simplenews then checks for existing subscriber with that email address and updates the preferred language. This is pretty easy, but of course still misusable as there is no check. I'm concentrating on using double out for this language change.
In fact, I have several international clients who maintain multi-lingual newsletters. But they don't want to force subscribers to create an (drupal) account just to select a preferred language. That's why I made the (still incomplete) patch above (#5). If your experience says there's no much need of this, I'd be fine, too (saves me some time on generalising the patch) and we can close this issue again.
Regards,
Paul
Comment #8
miro_dietikerWhat you could do is making all subscribers signup.
There are modules that e.g. build usernames automatically from mail.
Then a signup could be mail + password + newsletter to signup.
After the signup users could use their account settings to change settings of preference...
Regarding subscriber settings / data and multilanguage, there's a huge need. But in the current situation i feel it's wrong to implement workarounds with incomplete coverage and exposure...
Comment #9
Simon Georges CreditAttribution: Simon Georges commentedMoving all feature request to 7.x.