Hello Readers,
I will show you how to copy text in clipboard without using ctrl+c.
<html>
<head>
<script type="text/javascript" src="jquery-1.8.0.min.js"></script>
<script src="jquery.zclip.js"></script>
<script>
$(document).ready(function(){
$("a#copy").zclip({
path:"ZeroClipboard.swf",
copy:function(){
return $("input#dynamic").val();
}
});
});
</script>
</head>
<body>
<input type="text" id="dynamic" value="clipboard" />
<a href="#copy" id="copy">Copy Now</a>
</body>
</html>
Here, the above code shows how to copy text using jquery. In this code we used jquery function, flash and the zclip clipboard plugin to perform this task.
0 Comment(s)