Completed
Last Updated: 07 Sep 2021 06:17 by ADMIN
Release 2021.R3
Bas
Created on: 28 May 2020 07:58
Category: Form
Type: Feature Request
48
Add support for hidden fields to the Form

Add support for hidden fields. There could be an alternative way of adding them to the Items collection, e.g.

.AddHidden()

Consider the cases when the hidden field is bound to a model field and when it isn't bound to the model. The latter could be a scenario involving antiForgeryTokens: 

<input type="hidden" name="__RequestVerificationToken" value="token" />

In both cases you should be able to set the value of the hidden field programmatically and submit it with the form.

3 comments
erwin
Posted on: 28 Jan 2021 19:26
Also [HiddenInput] attribute on the model should be respected.
Mark
Posted on: 15 Jan 2021 21:43
Also please note that using a hidden field should not display a space in the UI as the current work around using the editorTemplate (mvc) or a custom editor/editor function (kendo ui) does now.
Mark
Posted on: 15 Jan 2021 21:40
Of course the same functionality should be available to kendo ui libraries as well.