-
- 90 Posts
I’m working on a news site, and we need to give logged-on users the ability to subscribe to receiving news directly in their inbox every time a new article is posted on the site. Ideally, I’d like to offer those users time options, such as ’send news daily’ ’...hourly’ or ’...as soon as news item is added’. I’ve had a quick look through the options, but without instealling each of them, it’s hard to get a good indication which packages are capable of meeting these needs.
Any ideas?
Are you wanting emails be sent to their "inbox" or RSS feeds? It is unclear due to your subject. I’m not sure there is an existing solution that could achieve this with the various time options you are wanting to provide.
-
- 90 Posts
Apologies for the lack of clarity: my boss keeps calling it that so I’m in the habit now.
I need the news articles to be sent via e-mail to their inbox, so not an RSS feed. Alternatively, a notification that something new has been posted more often than once a day. The once a day part is the killer it seems...
The send immediately part is easy, just have a plugin listen to the OnDocFormSave event and send the email. Doing it on a schedule however is trickier; you can do it via a plugin listening to one of various events if you candepend on someone hitting the site often enough, but to be sure it gets sent exactly on a specific schedule, you’d need to setup a CLI script to execute from a cronjob on the server.
-
- 2,877 Posts
-
- 372 Posts
I wrote something for admins that notifies you the a document was new or modified.
http://modxcms.com/forums/index.php/topic,39714.msg240317.html#msg240317
But it is for only one address and it only sends a message not the content itself. You need to create a db table to store the subscribers emails or reference to their userid and the type of email they want digest or instant. You could then use a modified version of the plugin to loop through the new db table and run the digest snippet or the instant snippet. I am not sure what type of impact it would have on the server sending 500 emails at a time.
It really sounds like an RSS feed would be the ideal solution. Some email clients have the ability to read feeds (like Apple’s Mail program) maybe that what your boss is thinking of.
DropboxUploader -- Upload files to a Dropbox account.
DIG -- Dynamic Image Generator
gus -- Google URL Shortener
makeQR -- Uses google chart api to make QR codes.
MODxTweeter -- Update your twitter status on publish.