A new Extension, “Email Template Filter” is now available for download. Comments and feedback can be left here but if you discover any issues, please post it on the issue tracker.

At work we needed to be able to send highly customizable emails using Symphony, so I wrote this extension that allows you to create HTML emails using a normal Symphony page.

Version 1.0.13, 1 April 2009:

In previous versions of the extension, the filter itself would act like a datasource, so you had no way of knowing exactly what XML you where working with, now however you can select one or more datasources to read from. This unfortunately comes at the cost breaking backwards compatibility.

This looks great! I don't suppose this would have access to field data e.g. in order to send a confirmation email to an address submitted in an event's form? Also, can multiple templates/emails be attached to a single event? I'll definitely be playing with this over the 4 day weekend.. Thanks again!

Does this work with S2?

I swear I had answered your questions before ashooner, but I can't find where I did, so here goes; yes, you have access to all field data, via {entry/*}, and yes, you can attach multiple email templates to an event.

Nick, yep, it only works on S2.

To answer your other question:

Will that allow me to take around 7 form fields and send it via an email?

Yep, since you use a normal Symphony page to generate the email, you can do anything you'd normally do in Symphony, and have it sent as an email.

OK, well the document readme is not correct as it is asking for me to upload a folder that is not there, so I kind of made the folder and dragged all the files into it, and uploaded it to my extensions folder.

It was in my extensions, but when I tried to enable it, it wouldn't enable.

Ahh, yes. That's a Symphony bug that's been fixed, but I'll make my extension work with 2.0 anyway.

For now just edit extension.driver.php and at the bottom of the install function add:

return true;

That'll let Symphony enable it.

ok cool, so I can use this instead of the built in method?

You see I have a form with about 7 or 8 different form fields, I want that information to be sent to the client/owner of the site.

Have you tried it yet, I'd suggest doing so...

Yeah going to do it tomorrow. Now I have it installed and enabled.

Ok just had a look at the screengrab and I'm just a little confused.

How do I send for example info from this form:

  1. Create a section to store your data in
  2. Create a new page to generate the email
  3. Create a new template that uses the new page
  4. Attach the new filter to your event
  5. Test.

Ah right so I can create a section with all the different form related data, such as Name, Address, Email, Date of Wedding etc...

Then I have to create a new page to generate the email? Can you explain that a bit for me?

I hope you don't mind me asking the questions, but I want to be clear on how this works, and then perhaps I can translate for those who like me are more design than development.

Rowan, I downloaded 1.005 and renamed the unpacked folder to emailtemplatefilter and dropped into the extensions folder. I also added the return true; to the install() function, but it won't appear in the list at all. Any idea what could be causing it?

I'm on a fresh, local 2.0 install.

I've had this with other extensions, in that it's been trial and error with renaming the folder (if no readme.txt is included) since the unpacked folder is often named the same as the Zip.

Then I have to create a new page to generate the email? Can you explain that a bit for me?

Well, just create a normal page as you would in symphony, make it display the information you want to send in the email, then in your email template, in the correct condition, choose the page from the dropdown box. Optionally you can choose which page params to send, using xpath: {entry/*}.

Nick Dunn, not really sure, I'd suggest clearing your manifest/logs/main file then trying to install it again, perhaps there's an obvious error?

@Rowanjl, is that a necessary step? Or can I just use my contact page?

Nick, the contact page is for accepting the data right? Well, you need another page to generate the email to be sent (of course, it could probably be the same page, but I wouldn't recommend it). Basically, as long as the 'email page' outputs HTML, it can be sent.

Hmm, do you have an example of this. Like a step by step - because its really confusing me.

I created a template like this:

Subject = Customer Enquiry Sender Name = {entry/name} Senders = {entry/email} Recipients = Technical Expression = nothing in here because I don't know what to put in here Page = contact-us Params = nothing in here because I don't know what to put in here.

I basically want to send all the information gathered from this form:

Also, I suppose you would suggest that for the contact form page I remove the built in event that came with S2.

So how would I confirm the information has been sent?

Actually, I think this isn't going to work for what I want.

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details