PHP Order Form

The PHP Order Form displays a customizable list of products which allows the user to select items, choose quantity and view totals and subtotals. The order form is JavaScript enhanced but not dependent upon JavaScript.

Two example order forms are provided: example one includes a standard PayPal button, sending the total and other order information for payment to your account. The second example includes contact information fields and sends an order email to an address you specify.

Order Form Features

The order form is built from an array listing products and their prices. The code requires php version 5.2+ due to its use of json_encode and version 5 object-oriented features.

The order form is built using small table and form classes for clean coding, separating markup from logic for ease of customization.

Although the examples currently provided don't include such features such as sales tax, and calculation of shipping costs, these could be added, as could other product types with options such as size, color, etc.