Welcome aboard! We are happy you are here and wish you good net-raft!
<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.0/jquery.min.js "></script>
<script src="https://net-raft.com/plugins/jquery/copy_to_clipboard/copyToClipboard.js" type="text/javascript"></script>
<script>
$(document).ready(function () {
$("#btn1").click(function () {
$("#p1").copyToClipboard($("#p1"));
});
$("#btn2").click(function () {
$("#p2").copyToClipboard($("#p2"));
});
});
</script>
</head>
<body>
<div id="p1">xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
xxxxxxxxxx</br>
</div>
<p id="p2">Hello World!</p>
<button id="btn1">Copy text 1</button>
<button id="btn2">Copy text 2</button>
<br/><br/><textarea rows="20" cols="30" placeholder="paste here"/></textarea>
<br/><br/><input placeholder="paste here"/>
</body>
</html>
The most helpful JQUERY solutions
plugin get client ip address using jqueryJQUERY Click to see more ... 10.4K 1.8K