开发者

SharePoint And JavaScript not working

开发者 https://www.devze.com 2022-12-22 06:08 出处:网络
I have created a SharePoint web site and I used SharePoint Desginer 2007 to update the Master page file in order to make the web site not accessible using any web prowser except IE. The code works jus

I have created a SharePoint web site and I used SharePoint Desginer 2007 to update the Master page file in order to make the web site not accessible using any web prowser except IE. The code works just fine for my user account, but the rest of the users can open the site with any browser.

<script language="javascript" type="text/javascript">

function detectBrowser()
{
  var browser=navigator.appName;
  var b_version=navigator.appVersion;
  var version=parseFloat(b_version);

  if ((browser=="Microsoft Internet Explorer") && (version>=4))
  {
    javascript:if (typeof(_spBodyOnLoadWrapper) != 'undefined') _spBodyOnLoadWrapper();
  }
  else
  {
    window.location = 'http://sharepoint:1010/error.htm'
  }
}

setTimeout("location.reload();",100000);
</script>

</HEAD>
开发者_开发知识库<BODY scroll="yes" onload="detectBrowser()">


I finally discovered the issue: I did not update the master page version on the MOSS.

Now it's working fine.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号