Hi!

I've made some, at least for my purposes, improvements to the already excellent simplenews module and wanted to share.

I wanted to be able to put !username in the newsletters for all subscribers, (personalized emails) that meant adding an optional name field to the simplenews_subscriptions table and the subscription block form, I also wanted to keep track of how long people had subscribed for, so I added a timestamp field also to the db table. Making this functional required a lot of functions to be modified in the module code. I also made it so email lists can be imported and exported with an optional name like this:

email | name,
email | name,
...

I also wanted to be able to put a custom anti-spam policy message just below the subscribe block form, so I added the option in the admin page for the module. I also got rid of the radio button in the form so the submit bottom just says 'subscribe' and subscribers can unsubscribe via the link in the newsletters.

I've attached the whole module directory with files I've changed for anyone else to use. Enjoy!

CommentFileSizeAuthor
#1 simplenews.zip21.05 KBjoehudson
simplenews.zip181.47 KBjoehudson

Comments

joehudson’s picture

StatusFileSize
new21.05 KB

There were some issues with the previous simplenews.module I uploaded. here's an updated version that also lets you have seperate email subject from the title. If you create a cck textfield called 'subject' for the newsletter node type it will be detected and used if it's been filled in instead of the title. A very handy feature I think! So now you can personalize the email subject and have a separate title for the newsletter.

(I just realized that I can, just using cck add a header and footer fields to the newsletter and set default values to give a kind of template to newsletters. Would would be very cool is a feature to inline css from a stylesheet for more reliable use with mailclients. So you have a text area field for a newsletter, put your css definitions in there then the styles get inlined outside the loop that customises the email body for language and tokens. I don't have time to do this unfortunately!)

sutharsan’s picture

Assigned: joehudson » Unassigned
Status: Needs review » Closed (won't fix)

Thanks for the code. However pls provide patches if you want to get new features into simplenews.
But from reading your feature description, your features are too specific (subscribe only block), not flexible enough (personalized emails) to be implemented or better ways are available (anti spam text: use hook_mail_alter instead).

However I am open to suggestions for adding code to simplenews to invoke new hooks.

faulkner161’s picture

Category: feature » support
Status: Closed (won't fix) » Active

I know you are developing this for 6.x.1.x, but for those of stuck with Drupal 5, I would really like to be use this module with personalised names from a webform or from signing up to our site. I am at a complete loss at the moment to see how else this is possible...

sutharsan’s picture

Status: Active » Closed (fixed)

No activity, closing the issue.

claudiu.cristea’s picture

Try Views Send. It allows personalization and full recipient list filtering based on Views.