【问题标题】:Content stealing in wordpress: Redirection if browser has javascript disabledwordpress 中的内容窃取:如果浏览器禁用了 javascript,则重定向
【发布时间】:2019-02-12 14:30:24
【问题描述】:

我对内容窃取者有一些严重的问题,他们窃取我的内容并在他们的网站上发布广告。所以我安装了一个内容保护插件,但是禁用了 javascript,窃取者也有机会窃取我的内容。

我发现代码很少和平,但它并没有阻止页面加载,只显示一条消息,以便窃取者也可以使用crtl+u查看源代码:

    <div id="noscript" 
         style="position:fixed;
                z-index:999999;
                text-align:center;
                padding:150px;" >
    <h2>Enable JavaScript!</h2>
    <p>Sorry for the inconvenience but you must enable JavaScript in your 
       Browser to visit this site!</p>
    <p>&mdash; The Team</p>
    </div>
    <script type="text/javascript">
    document.getElementById('noscript').style.display="none";
    </script>

有没有人有一点 php 代码,如果未启用 javascript,则可以重定向到 html 站点。谢谢。

【问题讨论】:

  • 复制您的内容的人仍然可以使用无头浏览器,该浏览器可以解释 javascript 并绕过您的保护进行复制。可靠的爬行保护非常困难。

标签: javascript wordpress redirect


【解决方案1】:

这样试试

<noscript>
  <meta http-equiv="refresh" content="0;url=noscript.html">
</noscript>

【讨论】:

  • thx,是的,我试过了,但这对像 umatrix 这样的浏览器扩展没有影响
  • 这里的问题是客户端浏览器不在您的代码中
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2012-01-11
  • 2016-11-13
  • 2011-03-16
  • 1970-01-01
  • 2021-07-16
  • 1970-01-01
  • 2017-06-11
相关资源
最近更新 更多