copyToClipboard is a simple plugin for copying the content of a container to the clipboard using jQuery. jQuery copy to clipboard plugin that enables the button to copy any text within the container element to the user’s clipboard.
copy to clipboard jquery, javascript copy to clipboard without input, copy to clipboard jquery, copy to clipboard javascript, jquery copy to clipboard div
Copy to Clipboard jQuery Plugin | CTCP
How to make use of it:
1. Load the primary JavaScript file copyToClipboard.js
after jQuery.
<script src="/path/to/cdn/jquery.slim.min.js"></script> <script src="/path/to/src/copyToClipboard.js"></script>
2. Attach the copy to clipboard to your component whose content material will probably be copyied to the clipboard.
<pre class="test"> ... Content Here ... </pre>
$(function(){ $('.test').copyToClipboard(); });
3. Customize the textual content to be displayed within the copy to clipboard button.
$(function(){ $('.test').copyToClipboard({ buttonText: 'Copy (Without Callback)', }); });
4. Trigger a callback function and return the info you simply copied.
$(function(){ $('.test').copyToClipboard({ buttonText: 'Copy (With Callback)', callback: function(data) { console.log(data); } }); });
5. Apply your individual styles to the copy to clipboard button.
.copyToClipboard-button { background: black; position: absolute; right: 0px; top: 0px; display: none; cursor: pointer; padding: 5px; }
Copy To Clipboard Button Plugin, copyToClipboard Github, html copy to clipboard without javascript, textarea copy to clipboard
See Demo And Download
Official Website(BurosystemhausSchafer): Click Here
This superior jQuery/javascript plugin is developed by BurosystemhausSchafer. For extra Advanced Usages, please go to the official website.