织梦dedecms复制文章内容自动加版权代码

复制文章内容时,自动版权文章详细页网址的实现方法:

将下面的js代码插入到文章内容页模板的<head>与</head>标签中间就行

<script language=”javascript” type=”text/javascript”> <!– document.body.oncopy = function () { setTimeout( function () { var text = clipboardData.getData(“text”); if (text) { text = text + “\r\n文章来自:darren中详文参考:”+location.href; clipboardData.setData(“text”, text); } }, 100 ) } –> </script>  

只需要写上上面的版权代码,那么功能就已经OK了.

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:http://www.heiqu.com/60c2a58e648b67d7de29b046154e9a78.html