
Public Member Functions | |
| setFormMessage ($xml="") | |
| Set the form message to be the output XML from an XForm. | |
Private Member Functions | |
| recurseForm ($xml) | |
| Recursively parse the XForms XML, adding each value as a line of text. | |
| recurseFormHelper ($xmlObject) | |
| Do the recursive work of parsing our XForms XML and converting it to text. | |
An extension of the Mailer class that parses the output XML of an XForm and adds it to an outgoing email.
Definition at line 12 of file FormsMailer.php5.
| FormsMailer::recurseForm | ( | $ | xml | ) | [private] |
Recursively parse the XForms XML, adding each value as a line of text.
For internal use only.
Call recurseFormHelper() to do the recursive traverse of the XForms XML
| $xml | [string]: The XForms XML |
Definition at line 35 of file FormsMailer.php5.
References recurseFormHelper().
Referenced by setFormMessage().
| FormsMailer::recurseFormHelper | ( | $ | xmlObject | ) | [private] |
Do the recursive work of parsing our XForms XML and converting it to text.
For internal use only.
For each tag in our XForms XML, look at the name and value of the tag. Add a line of text to our output in the following format: Name: Value
If a node has children, recursively parse those as well.
| $xmlObject | [simplexml_object]: A node of the XForms XML as a simplexml_object |
Definition at line 51 of file FormsMailer.php5.
References XFormsFunctions::contentFromXML().
Referenced by recurseForm().
| FormsMailer::setFormMessage | ( | $ | xml = "" |
) |
Set the form message to be the output XML from an XForm.
This function accepts an XML string that is the output XML from an XForm. It then parses through the XML string, formatting the name and value of each node as pretty output for email. Finally, it sets the message content to be the formatted XML output.
| $xml | [string]: Output XML from XForms |
Definition at line 22 of file FormsMailer.php5.
References recurseForm().
1.5.6