zoukankan      html  css  js  c++  java
  • turning on full error Messages

    One of the first things you will realize when working on your custom master page is that when you

    make a mistake, SharePoint’s default error messages are rather unhelpful. As mentioned earlier, if

    you omit one of the required content placeholders and browse a site that uses your master page,

    SharePoint will reply with simply “An unexpected error has occurred.” The first time this happens,

    it’s hard not to respond with some choice curse words and give up completely on SharePoint, but

    don’t throw in the towel yet. SharePoint can actually return descriptive error messages, but they

    are turned off by default for security reasons. If you are working in a development environment,

    though, it’s imperative to enable these full error messages.

    Here are the steps for turning on the full error messages:

       1.        Log in to the physical SharePoint Server machine and navigate to the directory that

    holds your SharePoint website. It will most likely be located at C:\inetpub\wwwroot\

    wss\VirtualDirectories\ and will be in a subdirectory with the port number of your

    SharePoint site. If you have trouble fi nding it, you can open IIS7 and in the Sites folder, rightclick

    your SharePoint site, and then select Explore. This will take you directly to the directory

    that holds your SharePoint website.

        2.        Locate the fi le named web.config and open it for editing in Notepad.

        3.        Press Ctrl+F and fi nd the line of code that contains the word “callstack.” You will fi nd a line

    that looks like this:

    <SafeMode MaxControls=”200” CallStack=”false” DirectFileDependencies=”10”

    TotalFileDependencies=”50” AllowPageLevelTrace=”false”>

         4.        Press Ctrl+F again and this time search for the word “errors.” You will fi nd a line that looks

    like this:

    <customErrors mode=”On” />

    Change the mode from On to Off. This tells IIS not to show its customary basic error messages

    and to instead display the raw detailed error messages.

         5.        Save and close web.config. Note that this change will cause IIS to restart the web application

    in which your SharePoint site resides. Be careful when making edits to this fi le in production

    or shared development environments.

  • 相关阅读:
    mac安装浏览器同步测试工具
    感觉自己不幸福怎么办?
    React组件
    常用的网页加载进度条
    浅析百分百还原网站效果图的可行性分析
    关于后台权限
    第一阶段:Python开发基础 day04  Python基础语法入门--Python基本数据类型
    第一阶段:Python开发基础 day03 Python基础语法入门--Python基础知识
    第一阶段:Python开发基础 Python基础语法入门  day03 课后作业
    第一阶段:Python开发基础 基础语法入门-- day02 编程语言分类
  • 原文地址:https://www.cnblogs.com/yanlixin/p/2432782.html
Copyright © 2011-2022 走看看