How to add placeholder attribute to JSF input component?

后端 未结 9 924
耶瑟儿~
耶瑟儿~ 2020-11-28 09:19

Shouldn\'t this line of code render a inputtext field with the placeholder text \"fill me\" when using html5?


         


        
9条回答
  •  爱一瞬间的悲伤
    2020-11-28 09:45

    Use primeface 4.0. Versions below this version do not support the placeholder attribute.

    1. use name space xmlns:pt="http://java.sun.com/jsf/passthrough".

    2. p:inputTextarea id="textAreaValue" pt:placeholder="your text"

      don't insert a new line in inputTextArea.

提交回复
热议问题