Rss-to-email for use with concrete5

Permalink 1 user found helpful
Hi all,

new to C5, but definitely see potential! Working on a site for a client, where the user-base is not super tech-savvy. Need to find a way to enable the clients site to send updates by e-mail to their mailing-list subscribers whenever the client posts a new update on their site.

I've been poking around online, but can't seem to find any solutions that won't set my client back $20-$50 / month, which is not an option: a one-time fee of $20-50 would be OK, but they're a small business, and need to cut all of their costs at the moment (I'm working for them practically for free - karma and all that... :-) ).

Any suggestions and help much appreciated! :-)

Best regards,
Johan

jlehmann
 
frizzleb replied on at Permalink Reply
frizzleb
Are you referring to when a client makes a content update or blog post?

If so you could use the override system to make concrete5 send the emails when new content is published and some simple modifications to the mailing list add-on could meet your demands.

Please note this is just of the top of my head.
jlehmann replied on at Permalink Reply
jlehmann
hi frizzleb,

thanks for getting back to me! The client wants to be able to have an e-mail sent out to the sites mailing-list, whenever they post news on their news page / blog, so that they can update the site AND notify their mailinglist "in one fell swoop", without having to copy-paste their news-article and then send it by mail afterwards.

Hope this clarifies it? :-)

Best regards,
Johan
frizzleb replied on at Permalink Reply
frizzleb
So effectively you need to export the blog page to html and then send that data in an email. Will think of the best solution and get back unless someone gets there first.
jlehmann replied on at Permalink Reply
jlehmann
Yup, that sounds right? Maybe one could couple this with the mailinglist add-on, in order to achieve both HTML and plaintext? Just thinking out loud here... :-)
frizzleb replied on at Permalink Reply
frizzleb
I belive i have an answer, i would recommend using page events e.g. on_page_version_approve. When this function is triggered you could gather the content from each block on the page using Areas.

If you would like some example code please ask.

Regards Frazer.
jlehmann replied on at Permalink Reply
jlehmann
Hi Frazer,

mkay...that went COMPLETELY over my head? *grins* Been using Concrete5 for about a week now, so yes: *please* show me some example code! :-)

Best regards,
Johan
frizzleb replied on at Permalink Reply
frizzleb
:) You will need to change some of the config first
If you go to the config/site.php file and add this line of code
define('ENABLE_APPLICATION_EVENTS', true);

This will make is possible to trigger the mailing list when the page is published.
jlehmann replied on at Permalink Reply
jlehmann
Done! - now what? I should probably buy the mailinglist add-on methinks? Do I do this from the site I'm building, or from concrete5.org?
frizzleb replied on at Permalink Reply
frizzleb
If i recall the next stage would be to setup a an event in the blog page type
Events::extendPageType('blog_page', 'on_page_version_approve');

blog_page should be replaced with the name of the page type you are using for the blog.

Inside the blog_page.php (or whatever the name is) add
function on_page_version_approve {
//Get data from page Areas and trigger mailing list model.
}
frizzleb replied on at Permalink Reply
frizzleb
Just to add there is a free mailing list addon, i think.
frizzleb replied on at Permalink Reply
frizzleb
If you want i could write a simple package to overide the blog page and then call the mailing list model if you would like.

I am not at home write now but could give it a shot when i get back.
jlehmann replied on at Permalink Reply
jlehmann
Frazer: that would be above and beyond! You sure you've got the time to do this? I mean, I've set aside 2 weeks to build this site, seeing as it's my first C5 project, and I figured I'd definitely need a good poke-around to familiarize myself with the tool, but I'm guessing you probably have other things to do...? ;-)
jlehmann replied on at Permalink Reply
jlehmann
Really? I just bought 5 licenses of Tony's Mailing List...doh! :-)
jlehmann replied on at Permalink Reply
jlehmann
OK - how do I "setup a an event in the blog page type"? Is this done from within C5, or through the backend via FTP?
frizzleb replied on at Permalink Reply
frizzleb
HAHAHAAHAH, it seems students have all the time in the world!

/* To setup an event add this also to config/site.php
Events::extendPageType('blog_page', 'on_page_version_approve');
/* Then add this to the page type file (This could be in a number of places, most of the time in the theme.
function on_page_version_approve {
}
frizzleb replied on at Permalink Reply
frizzleb
This needs to be done from the php backend