$(function(){
$(' #copy_input').zclip({
path: 'js/ZeroClipboard.swf',
copy: function(){//Copy content
return $('#mytext').val();
afterCopy: function(){//Copy successfully ('Copied successfully');
}
});
});
It is worth noting that if the copied content comes from input box input, textarea, etc., use the copy object:
copy: function(){
return $( '#mytext').val();
}
If the copied content comes from page elements div, p, etc., use the copy object:
copy: $('#mytext').text( );
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn