PHP Classes
Icontem

File: example_elements.php


  Search   All class groups All class groups   Latest entries Latest entries   Top 10 charts Top 10 charts   Newsletter Newsletter   Blog Blog   Forums Forums   Help FAQ Help FAQ  
  Login   Register  
Recommend this page to a friend! ReTweet ReTweet Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Thiemo Mättig  >  TM::Apeform  >  example_elements.php  
File: example_elements.php
Role: Example script
Content type: text/plain
Description: How to use the special elements from the extended class
Class: TM::Apeform
A very abstract web form builder and processor
 

Contents

Class file image Download
<?php

/**
 * Extended form elements example. Shows use of an extended class to provide
 * some special form elements with build in error checking.
 *
 * @author Thiemo Mättig (http://maettig.com/)
 */

// Include the extended class.
require_once("example_elements.class.php");

// Instantiate an object from this class.
$form = new ExtendedApeform();

// Add some of the extended input fields to the form.
$date $form->date();
$date $form->dateSelector();
$email $form->email();
$date $form->price();
$image $form->filetype("<u>I</u>mage""JPG, PNG etc. only""image/*"10,
    
true);
$form->submit();

// Process the form if it was submitted error-free.
if ($form->isValid()) echo "Thank you!";
else 
$form->display();

?>

 
  Advertise on this site Advertise on this site   Site map Site map   Statistics Statistics   Site tips Site tips   Privacy policy Privacy policy   Contact Contact  

For more information send a message to :
info at phpclasses dot org.
Copyright (c) Icontem 1999-2009 PHP Classes - PHP Class Scripts
  PHP Book Reviews - Reviews of books and other products