Edit This Code:
See Result »
<
!DOCTYPE
html
>
<
html
>
<
body
>
<
p
oncopy
="myFunction()"
>
Try to copy this text
<
/p
>
<
script
>
function
myFunction() {
alert(
"You copied text!"
);
}
<
/script
>
<
/body
>
<
/html
>
<!DOCTYPE html> <html> <body> <p oncopy="myFunction()">Try to copy this text</p> <script> function myFunction() { alert("You copied text!"); } </script> </body> </html>
Result:
Privacy Policy