PhpRiot
Become Zend Certified

Prepare for the ZCE exam using our quizzes (web or iPad/iPhone). More info...


When you're ready get 7.5% off your exam voucher using voucher CJQNOV23 at the Zend Store

Eight Weeks of Prototype: Week 8, A Complete Prototype Example

Summary

In this article we have created a simple contacts manager, which allows you to create contacts using a HTML form. The contacts are submitted via Ajax to the server which then processes the form values and saves the new contact to the database. 

Additionally, the contacts manager retrieves a list of existing contacts using Ajax and displays them on the page. When a new contact is added we use custom events so it can be added to the list of contacts. 

While the application isn't overly useful as it currently is (since it lacks several key features such as being able to edit and delete contacts), it does demonstrate the general thought process and structure of a larger application. 

This now concludes the Eight Weeks of Prototype series, which I hope has not only helped you learn the key aspects of the Prototype JavaScript framework, but also given you further ideas of how to develop JavaScript in general. 

Other Options

In This Article