Created
September 17, 2010 03:17
-
-
Save andreia/583604 to your computer and use it in GitHub Desktop.
form iterator - sf 1.4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="ui-corner-all"> | |
<?php foreach($form->getFormFieldSchema() as $formField): ?> | |
<div class="form_field_<?php echo $formField->getName() ?><?php $formField->hasError() and print ' ui-state-error ui-corner-all' ?>"> | |
<div class="label ui-helper-clearfix"> | |
<?php echo $formField->renderLabel(); ?> | |
</div> | |
<?php if($help = $formField->renderHelp()): ?> | |
<div class="help"> | |
<span class="ui-icon ui-icon-help floatleft"></span> | |
<?php echo strip_tags($help) ?> | |
</div> | |
<?php endif; ?> | |
<?php echo $formField->render() ?> | |
<?php if($formField->hasError()): ?> | |
<div class="errors"> | |
<span class="ui-icon ui-icon-alert floatleft"></span> | |
<?php echo $formField->renderError() ?> | |
</div> | |
<?php endif; ?> | |
</div> | |
<?php endforeach ?> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment