Today we can "Add new [standard] mailing list" or "Import lists from Data Type" but that is not flexible enough for us.
We need a new “Import list from Function” option that returns custom XML.
The XML should have a predefined element structure with one predefined attribute called "email" and a free number of custom attributes.
The XML structure could be like this:
<Members email=”email@example.com” name=”Søren Larsen” shoesize=”42” />
I might be tricky so maybe we need to discuss the possible solutions.
Mar 22, 2011 at 9:42 AM
Edited Mar 22, 2011 at 9:45 AM
This is great idea.. and it's done & online now! Please check
Composite.Community.Newsletter version 1.5.1 - it's containing FunctionBased mailing list support.
Quick how to import List from XSLT Function
XSLT function must return XML that lists members by using <Member /> element for each member. The <Member /> element must include the attribute named "Email" with a valid email address as its value. This element can also include custom attributes
(fo example, Name, Company, etc).
<Member Name="John Doe" Email="firstname.lastname@example.org" />
<Member Name="Jane Smith" Email="email@example.com" />
To import the list from an XSLT function:
1. In the Content perspective, select Newsletters and click "Import List from XSLT Function" on the toolbar.
2. Specify the Title and write the Description in the dialog.
3. Specify the XSLT Function that meets the requirements described above and click Finish.
If return XML from XSLT function changed (for example you added new field), you need just edit mailing list and re-save it - Newsletter will pickup new data structure.