


(收藏于闲鱼博客)之前有分享一篇《WordPress添加防止F12扒代码(两种)》,虽然不是所有人都感冒,但是聊胜于无嘛,总有喜欢的。这里闲鱼要说的又是一个和审查元素(F12)有关的小玩意儿,也是在百度F12看到了,给人有种F12小惊喜的感觉。虽然百度是用它来招聘……我们未尝不能做点其他的。
百度F12-Console效果
这个小功能觉得蛮有趣的,实现起来也很简单,一段小代码就行。
实现方法
将以下代码添加到footer.php
即可,按下F12或右键审查元素,找到Console就能看到效果,内容自己改哦。
- <script type=“text/javascript” language=“javascript”>
- if(window.console&&window.console.log){
- console.log(‘不好!被你发现了!’);
- console.log(‘既然你发现了这个隐藏的秘密,就准备受死吧!’);
- console.log(“%c现在求饶还来得及,留言谢罪吧:http://www.seoqe.com/liuyan.html”,“color:red”);
- }
- </script>




亲爱的:若该文章解决了您的问题,可否收藏+评论+分享呢?
文章评论 本文章有个评论