6b1107ed216e36a6a1c8ad2e186308b64be1b09a
[Packages/TYPO3.CMS.git] / typo3 / sysext / form / Resources / Private / Frontend / Partials / Field / Field.html
1 <html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers" xmlns:formvh="http://typo3.org/ns/TYPO3/CMS/Form/ViewHelpers" data-namespace-typo3-fluid="true">
2 <f:form.validationResults for="{element.identifier}">
3 <div class="form-group{f:if(condition: '{validationResults.errors.0}', then: ' has-error')}">
4 <f:if condition="{doNotShowLabel} != 1">
5 <label class="control-label" for="{element.uniqueIdentifier}">{formvh:translateElementProperty(element: element, property: 'label')}<f:if condition="{element.required}"><f:render partial="Field/Required" /></f:if></label>
6 </f:if>
7 <div class="{element.properties.containerClassAttribute}">
8 <f:format.raw>
9 {elementContent}
10 <f:if condition="{validationResults.flattenedErrors}">
11 <span class="error help-block" role="alert">
12 <f:for each="{validationResults.errors}" as="error">
13 {formvh:translateElementError(element: element, code: error.code, arguments: error.arguments, defaultValue: error.message)}
14 <br />
15 </f:for>
16 </span>
17 </f:if>
18 </f:format.raw>
19 <f:if condition="{element.properties.elementDescription}">
20 <span class="help-block">{formvh:translateElementProperty(element: element, property: 'elementDescription')}</span>
21 </f:if>
22 </div>
23 </div>
24 </f:form.validationResults>
25 </html>