News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Jani Hartikainen's Blog:
Complex custom elements in Zend_Form
October 23, 2008 @ 12:09:55

In this new post Jani Hartikainen shows a quick and easy method for creating a custom form element in your Zend Framework application. His example is a custom time element.

The alternatives would be creating custom view helpers to output the custom form elements, and using the viewscript decorator. Creating a custom view helper would also require a custom form element class, and it would be a bit tricky. [...] I think the viewscript approach is the most flexible and simplest to implement, so I chose to go with that.

His example defines a time field made up of three drop down lists, one each for hours, minutes and seconds. Included is the code to make the element (including a regular expression for validation) and the view script to display it.

0 comments voice your opinion now!
zendform zendframework complex custom element time tutorial


blog comments powered by Disqus

Similar Posts

Jeremy Cook's Blog: Installing Imagick under Apache on Windows

Lorenzo Alberton's Blog: Navigation Through Paragraphs in an Article

Fabien Potencier's Blog: Create your own framework... on top of the Symfony2 Components (part 12)

Evan Coury: Creating a simple view helper in Zend Framework 2

ParanoidFerret.com: Using Flex, PHP, and JSON to Modify a MySQL Database


Community Events

Don't see your event here?
Let us know!


laravel podcast performance series interview php7 testing introduction voicesoftheelephpant application framework release version composer api opinion example library community symfony2

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework