简单的Javascript代码行

Kev*_*vin 4 javascript

在我们的大多数页面上都有这行代码,我正在试图找出它的用途以及是否可以删除它.

它看起来像这样:

<script type="text/javascript">
  /*<![CDATA[*/
  if(top!=self){top.location.replace(self.location.href);}
  /*]]>*/
</script>
Run Code Online (Sandbox Code Playgroud)

我知道这可能是一个愚蠢的问题,但是这个剧本试图说的是什么.这可能与登录功能有关吗?

提前致谢

Pau*_* S. 10

if (top != self) { // if the top frame isn't this window
    top.location.replace( // set the top frame's location
        self.location.href // to this window's location
    );
}
Run Code Online (Sandbox Code Playgroud)