servlets struts hibernate spring maven java
 

JSF <h:inputTextarea> Tag



JSF renders this as an HTML "textarea" element. It allows a user to enter multiline string.

Example

  1. <h:inputTextarea id="text-area-id" value="#{user.address}" required="true"   
  2. requiredMessage="Address is required" cols="50" rows="10"></h:inputTextarea>  

JSF renders <h:inputTextarea> tag as below:

  1. <textarea id="user-form:text-area-id"  
  2. name="user-form:text-area-id" cols="50" rows="10"></textarea>  

Attribute

Attribute Description
id It is an identifier for this component. This id must be unique. You can use it to access HTML element in CSS and JS file.
value It holds current value of this component.
cols It is used to set number of cols for the textarea.
rows It is used to set number of rows for the textarea.
required It indicates that the user is required to provide a submitted value for this input component.
requiredMessage If required attribute is set to true, the message description provided in the requiredMessage is display to the web page.
disabled It is used to disabled component. You can disabled it by assigning true value.
onclick It is method which invokes JavaScript code after onclick on the textarea.
onselect It is a method which invokes JavaScript code when a user select this component.
readonly It indicates that this component prohibits changes by the user. You can make component readonly by passing readonly as a value of this attribute. eg. readonly = "readonly"
rendered It is used to render this component. You can set it's value true or false. Default value is true.
label It is used to set a localized name for this component.
lang It is used to set language for this component.
style It is used to set CSS style code to provide better user interface of this component.
accesskey Access key that, when pressed, transfers focus to this element. It varies browser to browser.





© Javacodegeeks © 2019 - 2019
All Right Reserved and you agree to have read and accepted our term and condition.

Python 3