Sending Email with an SMTP Client Built with Prototype and PHP
If you're a web developer who wants to acquire a solid background in building applications with the popular Prototype JavaScript library, then this set of articles may be what you're looking for. Welcome to the last installment of the series that began with "Building an SMTP Client with Prototype." Made up of three friendly tutorials, this series teaches you how to use this powerful software package to create a highly expansible email application that works with most modern browsers.
Sending Email with an SMTP Client Built with Prototype and PHP - The complete client-side code of the SMTP application (Page 2 of 4 )
Before I show you the signature of the PHP script that sends email using the data entered in the web form included in the corresponding user interface, first I'd like to list the full client-side code that belongs to the SMTP client, so you can quickly recall how it looked originally.
Given that, here is the pertinent code listing. Have a look at it, please:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
So far, so good. Having listed the complete client-side code that corresponds to the SMTP client, it's time to move forward and take the next step involved in the development of this Prototype-based application.
As I mentioned before, we now need to create a simple PHP script which will be capable of sending email messages using the data provided by the user, that is the respective recipients, subject and text of the message in question, and so forth.
Therefore, in the section to come I'm going to build the aforementioned PHP script, in this way completing the development of this SMTP client.
Want to see how this step will be taken? Click on the link that appears below and keep reading.