Sample Code

Email Form class email_BasicContact, class email_PreviewEmail

Purpose: A php class that displays an email submission form, validates the input, and sends the email.

There are two main classes to this sample, both in the previously mentioned control/view format. The first example, email_BasicContact, illustrates the use of logic in a control method to determine component state from the input as opposed to acheiving it through a series of redirects between script pages. The second class, email_PreviewEmail, is an example of using class inheritance to override and extend component behavior--in this case to add a preview state to the component.