Skip to content

dave08/sfUniFormPlugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Usage

Use this plugin by first initializing the scripts used:

include_uniform();

Then by inserting this to display the fields:

echo uniform_render($form, array(
	'type',
	'=Materials' => array(
		'medium_id','surface_id'
	),
	'=Dimensions' => array(
		'width','height'
	),
	'price',
	'status'
));

The sub arrays are for multi field sections and an '=' sign indicates if you want to use the alternate layout for those fields.

Alternatively the UniForm class could be used.

This plugin has been locally unit tested for most of what it does using the sfPhpUnit plugin and my own classes for db inclusion, so I just included the tests to see the functionality for now, maybe I'll be including a fork to sfPhpUnitPlugin and some proper tests w/ less external dependencies.

TODO

  • Support automatic indication of required values "*"
  • Support data-default-value="Placeholder text" ? size="35" maxlength="50" are used specially in the framework?
  • Support different text field sizes
  • %help% %error% and %hiddenfields% support in multi field row

About

A symfony plugin for the UniForm form framework

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published