Clipboard is adding '\n' instead of a line break
Posted: 16 Jul 2021, 12:31
Having issue with the clipboard copmonant where it is unable to convert \n into new line.
Here is the code in Xhtml:
Expected output:
Here is the code in Xhtml:
Code: Select all
<p:commandButton id="cmdCopyQueAns" action="#{pc_inprocessBean.copyQueAns()}" immediate="true"
ajax="true" value="#{candidateLbl['scrQueAns.copy']}" styleClass="btn btn-primary" update=":frm:messages"/>
<pe:clipboard id="clipCopy" trigger="cmdCopyQueAns" action="copy" text="#{pc_inprocessBean.selectedCandVO.cndJobQueAns}"/>
What i am getting:Add your Email:abc@abc.com
Add your name:Abc
Any Idea on how to resolve this?Add your Email:abc@abc.com\n\nAdd your name:Abc