Forum:Template to copy some text to clipboard

The idea consists of wrapping  and having a 'copy' button beside. This will allow the editors to copy the preformatted text by a simple click, rather than doing drag-drop-block, and copy-paste. Can someone suggest an appropriate javascript for my needs?