Form ViewHelper Reference
This reference was automatically generated from code on 2024-10-23
neos.form:form
Custom form ViewHelper that renders the form state instead of referrer fields
- Implementation:
Neos\Form\ViewHelpers\FormViewHelper
Arguments
additionalAttributes
(array, optional): Additional tag attributes. They will be added directly to the resulting HTML tag.data
(array, optional): Additional data-* attributes. They will each be added with a “data-” prefix.enctype
(string, optional): MIME type with which the form is submittedmethod
(string, optional): Transfer type (GET or POST or dialog)name
(string, optional): Name of formonreset
(string, optional): JavaScript: On reset of the formonsubmit
(string, optional): JavaScript: On submit of the formaction
(string, optional): Target actionarguments
(array, optional): Argumentscontroller
(string, optional): Target controller. If NULL current controllerName is usedpackage
(string, optional): Target package. if NULL current package is usedsubpackage
(string, optional): Target subpackage. if NULL current subpackage is usedobject
(mixed, optional): object to use for the form. Use in conjunction with the “property” attribute on the sub tagssection
(string, optional): The anchor to be added to the URIformat
(string, optional): The requested format, e.g. “.html”additionalParams
(array, optional): additional query parameters that won’t be prefixed like $arguments (overrule $arguments)absolute
(boolean, optional): If set, an absolute action URI is rendered (only active if $actionUri is not set)addQueryString
(boolean, optional): If set, the current query parameters will be kept in the URIargumentsToBeExcludedFromQueryString
(array, optional): arguments to be removed from the URI. Only active if $addQueryString = truefieldNamePrefix
(string, optional): Prefix that will be added to all field names within this formactionUri
(string, optional): can be used to overwrite the “action” attribute of the form tagobjectName
(string, optional): name of the object that is bound to this form. If this argument is not specified, the name attribute of this form is used to determine the FormObjectNameuseParentRequest
(boolean, optional): If set, the parent Request will be used instead ob the current oneclass
(string, optional): CSS class(es) for this elementdir
(string, optional): Text direction for this HTML element. Allowed strings: “ltr” (left to right), “rtl” (right to left)id
(string, optional): Unique (in this file) identifier for this HTML element.lang
(string, optional): Language for this element. Use short names specified in RFC 1766style
(string, optional): Individual CSS styles for this elementtitle
(string, optional): Tooltip text of elementaccesskey
(string, optional): Keyboard shortcut to access this elementtabindex
(integer, optional): Specifies the tab order of this elementonclick
(string, optional): JavaScript evaluated for the onclick event
neos.form:form.datePicker
Display a jQuery date picker.
Note: Requires jQuery UI to be included on the page.
- Implementation:
Neos\Form\ViewHelpers\Form\DatePickerViewHelper
Arguments
additionalAttributes
(array, optional): Additional tag attributes. They will be added directly to the resulting HTML tag.data
(array, optional): Additional data-* attributes. They will each be added with a “data-” prefix.name
(string, optional): Name of input tagvalue
(mixed, optional): Value of input tagproperty
(string, optional): Name of Object Property. If used in conjunction with <f:form object=”…”>, “name” and “value” properties will be ignored.size
(int, optional): The size of the input fieldplaceholder
(string, optional): Specifies a short hint that describes the expected value of an input elementerrorClass
(string, optional): CSS class to set if there are errors for this view helperinitialDate
(string, optional): Initial date (@see http://www.php.net/manual/en/datetime.formats.php for supported formats)class
(string, optional): CSS class(es) for this elementdir
(string, optional): Text direction for this HTML element. Allowed strings: “ltr” (left to right), “rtl” (right to left)id
(string, optional): Unique (in this file) identifier for this HTML element.lang
(string, optional): Language for this element. Use short names specified in RFC 1766style
(string, optional): Individual CSS styles for this elementtitle
(string, optional): Tooltip text of elementaccesskey
(string, optional): Keyboard shortcut to access this elementtabindex
(integer, optional): Specifies the tab order of this elementonclick
(string, optional): JavaScript evaluated for the onclick eventdateFormat
(string, optional): Format to use for date formattingenableDatePicker
(boolean, optional): true to enable a date picker
neos.form:form.formElementRootlinePath
Form Element Rootline Path
- Implementation:
Neos\Form\ViewHelpers\Form\FormElementRootlinePathViewHelper
Arguments
renderable
(NeosFormCoreModelRenderableRenderableInterface): The renderable
neos.form:form.timePicker
Displays two select-boxes for hour and minute selection.
- Implementation:
Neos\Form\ViewHelpers\Form\TimePickerViewHelper
Arguments
additionalAttributes
(array, optional): Additional tag attributes. They will be added directly to the resulting HTML tag.data
(array, optional): Additional data-* attributes. They will each be added with a “data-” prefix.name
(string, optional): Name of input tagvalue
(mixed, optional): Value of input tagproperty
(string, optional): Name of Object Property. If used in conjunction with <f:form object=”…”>, “name” and “value” properties will be ignored.size
(int, optional): The size of the select fieldplaceholder
(string, optional): Specifies a short hint that describes the expected value of an input elementdisabled
(string, optional): Specifies that the select element should be disabled when the page loadserrorClass
(string, optional): CSS class to set if there are errors for this view helperinitialDate
(string, optional): Initial time (@see http://www.php.net/manual/en/datetime.formats.php for supported formats)class
(string, optional): CSS class(es) for this elementdir
(string, optional): Text direction for this HTML element. Allowed strings: “ltr” (left to right), “rtl” (right to left)id
(string, optional): Unique (in this file) identifier for this HTML element.lang
(string, optional): Language for this element. Use short names specified in RFC 1766style
(string, optional): Individual CSS styles for this elementtitle
(string, optional): Tooltip text of elementaccesskey
(string, optional): Keyboard shortcut to access this elementtabindex
(integer, optional): Specifies the tab order of this elementonclick
(string, optional): JavaScript evaluated for the onclick event
neos.form:form.uploadedImage
This ViewHelper makes the specified Image object available for its childNodes. In case the form is redisplayed because of validation errors, a previously uploaded image will be correctly used.
- Implementation:
Neos\Form\ViewHelpers\Form\UploadedImageViewHelper
Arguments
additionalAttributes
(array, optional): Additional tag attributes. They will be added directly to the resulting HTML tag.data
(array, optional): Additional data-* attributes. They will each be added with a “data-” prefix.name
(string, optional): Name of input tagvalue
(mixed, optional): Value of input tagproperty
(string, optional): Name of Object Property. If used in conjunction with <f:form object=”…”>, “name” and “value” properties will be ignored.as
(string, optional): Variable name to use for the uploaded image
Examples
Example:
<f:form.upload property="image" />
<c:form.uploadedImage property="image" as="theImage">
<a href="{f:uri.resource(resource: theImage.resource)}">Link to image resource</a>
</c:form.uploadedImage>
Expected result:
<a href="...">Link to image resource</a>
neos.form:form.uploadedResource
This ViewHelper makes the specified PersistentResource available for its childNodes. If no resource object was found at the specified position, the child nodes are not rendered.
In case the form is redisplayed because of validation errors, a previously uploaded resource will be correctly used.
- Implementation:
Neos\Form\ViewHelpers\Form\UploadedResourceViewHelper
Arguments
additionalAttributes
(array, optional): Additional tag attributes. They will be added directly to the resulting HTML tag.data
(array, optional): Additional data-* attributes. They will each be added with a “data-” prefix.name
(string, optional): Name of input tagvalue
(mixed, optional): Value of input tagproperty
(string, optional): Name of Object Property. If used in conjunction with <f:form object=”…”>, “name” and “value” properties will be ignored.as
(string, optional): Variable name to use for the uploaded resource
Examples
Example:
<f:form.upload property="file" />
<c:form.uploadedResource property="file" as="theResource">
<a href="{f:uri.resource(resource: theResource)}">Link to resource</a>
</c:form.uploadedResource>
Expected result:
<a href="...">Link to resource</a>
neos.form:render
Main Entry Point to render a Form into a Fluid Template
<pre> {namespace form=NeosFormViewHelpers} <form:render factoryClass=”NameOfYourCustomFactoryClass” /> </pre>
The factory class must implement {@link NeosFormFactoryFormFactoryInterface}.
- Implementation:
Neos\Form\ViewHelpers\RenderViewHelper
Arguments
persistenceIdentifier
(string, optional): The persistence identifier for the formfactoryClass
(string, optional): The fully qualified class name of the factory (which has to implement NeosFormFactoryFormFactoryInterface)presetName
(string, optional): Name of the preset to useoverrideConfiguration
(array, optional): Factory specific configuration
neos.form:renderHead
Output the configured stylesheets and JavaScript include tags for a given preset
- Implementation:
Neos\Form\ViewHelpers\RenderHeadViewHelper
Arguments
presetName
(string, optional): Relative Fusion path to be rendered
neos.form:renderRenderable
Render a renderable
- Implementation:
Neos\Form\ViewHelpers\RenderRenderableViewHelper
Arguments
renderable
(NeosFormCoreModelRenderableRenderableInterface)
neos.form:renderValues
Renders the values of a form
- Implementation:
Neos\Form\ViewHelpers\RenderValuesViewHelper
Arguments
renderable
(NeosFormCoreModelRenderableRootRenderableInterface, optional): Relative Fusion path to be renderedformRuntime
(NeosFormCoreRuntimeFormRuntime, optional): Relative Fusion path to be renderedas
(string, optional): Relative Fusion path to be rendered
neos.form:translateElementProperty
ViewHelper to translate the property of a given form element based on its rendering options
- Implementation:
Neos\Form\ViewHelpers\TranslateElementPropertyViewHelper
Arguments
property
(string): The property to translateelement
(NeosFormCoreModelFormElementInterface, optional): Form element