News Feed
Jobs Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Ian Christian's Blog:
Sending multipart email from a Task in symfony 1.4
December 16, 2009 @ 07:58:37

In a recent post to his blog Ian Christian has written up an example of how to send a multipart email from a Task inside your Symfony application.

I recently needed to send the result of an action in symfony via email daily. E-mail has changed slightly in symfony 1.3/1.4 - here's how I did it. I really don't like my solution at all, the use of get_partial() from within a Task seems very wrong to me - but I'm in a rush so it will do for now, I'd love to hear feedback.

His class extends the sfBaseTask and sets up an execute method that builds a database connection, fetches a few rows and, with a newly created mailer instance, sends the information using the get_partial method to define both HTML and text content parts of the email.

0 comments voice your opinion now!
multipart email task symfony tutorial


blog comments powered by Disqus

Similar Posts

The Geek Stuff: How to Configure Nginx to Execute PHP Using PHP-FPM

Make Me Pulse: Using Memcached with PHP Zend Framework

DesignShack.com: How to Build a Dynamic Imgur Upload App Using jQuery & PHP

NetTuts.com: Create Instagram Filters With PHP

Community News: Symfony Framework Makes Some Updates (v.0.6.2 and Content)


Community Events











Don't see your event here?
Let us know!


hhvm unittest security introduction facebook podcast performance framework overview install application opinion package hack component language composer release symfony2 database

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework