3.4.2. Hidden fields

The following topics are covered:

3.4.2.1. Non-value field
3.4.2.2. Non-editable fields
3.4.2.3. Create node type or mixin type
3.4.2.4. Hidden field with default value
3.4.2.5. Visible without null fields
3.4.2.6. WYSIWYG widget
3.4.2.7. Create a custom RichText editor fields
3.4.2.8. Simple select box widget
3.4.2.9. Advanced dynamic select box
3.4.2.10. Widget with selector
3.4.2.11. Multi-valued widget

In the next code sample, each argument is composed of a set of keys and values. The order of arguments are not important and only the key matters. That example defines a field with the id as "hiddenField2", which will generate a hidden field. The value of this field will be automatically set to UTF-8 and no visible field will be printed on the form.



String[] hiddenField2 = ["jcrPath=/node/jcr:content/jcr:encoding", "visible=false", "UTF-8"];
uicomponent.addHiddenField("hiddenInput2", hiddenField2);

Once the form has been saved, the date value will be saved under the relative JCR path ./exo:image/jcr:lastModified.

Copyright ©2012. All rights reserved. eXo Platform SAS