copy to clipboard in javascript

علی ذوالفقار
1400/12/22 08:20:59 (158)
use clipboardjs :
https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.10/clipboard.min.js
or get latest from github :
https://github.com/zenorocha/clipboard.js
in code use :
<script src="/js/clipboard.min.js">

ClipboardJS.copy('what you want to copy to clipboard');
Back