Controller is the class extending \FormLister\Core base class, which perfoms:
- loading classes to validate data and generate captcha;
- processing form data (form data here is the value of formData property, not only of
- processing form template and success template.
The way it works:
- Data are loaded from form.
- Data are loaded from external sources.
- Snippets are called to process data.
- Data validation if it's received from form;
- Snippets are called to process data again.
- Final processing - if data came from form and passed validation successfully.
Final processing is done by controller's
process() method. Result flag has to be set with
setFormStatus() method after successful processing, then fill
renderTpl property with template to output processing results.
These are some base controllers, feel free to extend them:
Sends e-mail using form data.
Creates users and sends needed notifications.
Processes a special link to confirm user registration or sends it via e-mail.
Allows users to delete their profiles. It requests password to confirm.
Allows users to edit their profiles.
Helps users to remind their passwords.
Allows to create and edit resources with MODxAPI classes.
Allows users to delete resources they created.
Adds users to MailChimp mailing lists. It's provided as example of \FormLister\Core class extension.
Suggest an edit to this page.