Clipboard Clipboard is for copying text to the clipboard. It shouldn't be hard and it shouldn't require dozens of steps to configure or hundreds of KBs to load. But most of all, it shouldn't depend on Flash or any bloated framework.

Based on Clipboard.js by Zeno Rocha.
Browser Supported
Components and more
Use Cases
Documentation pe:clipboard
Attributes (move mouse over the names to see data types)
Name Description
id Unique identifier of the component in a namingContainer.
rendered Boolean value to specify the rendering of the component, when set to false component will not be rendered.
binding An el expression referring to a server side UIComponent instance in a backing bean.
widgetVar Name of the client side widget.
action Action whether to 'copy' or 'cut'. Default is 'copy'.
trigger The trigger to execute the action. Typically a button.
target The target component to copy/cut the text from.
text If you don't use target you can set text to the value you want copied/cut. Default is 'PrimeFaces Rocks!' if you forget to set it.
onsuccess Javascript handler to execute if text is successfully copied/cut.
onerror Javascript handler to execute when text fails to copy/cut to clipboard.
Events (move mouse over the names to see classes)
Name Description
successfires when the clipboard sucessfully copies/cuts
errorfires when the clipboard fails to copy/cut
PrimeFaces Extensions Showcase - © 2011-2018, PrimeFaces: 6.2, PrimeFaces Extensions: 6.2.4, JSF: mojarra 2.3.2, Server: jetty/9.4.2.v20170220, Build time: 2018-04-10 14:26
Thomas Andraschko
Oleg Varaksin
Nilesh Namdeo Mali
Mauricio Fenoglio
Pavol Slaný
Sudheer Jonna