asp.net mvc - IIS Express - HTTP Error 500.19 0x800700b7 on 'mimeMap' for 'fileExtension' set to '.svg' -


I was adding the ability to serve SVG; WOFF files In my hosted web application, I have received the following instructions:

Which I have done by adding the following text to my web .config file:

  & lt; Staticcontent & gt; & Lt; MimeMap file extension = ".json" mimeType = "app / jason" /> & Lt; MimeMap file extension = ".svg" mimeType = "image / svg + xml" /> & Lt; MimeMap file extension = ".woff" mimeType = "app / x-font-woff" /> & Lt; / StaticContent & gt;  

This works when published in Ezur, however, whenever I use the website to start the website in debug mode for every resource of the website's efforts. IIS-Express gets the following error I

HTTP error 500.19 - Internal server error

The requested page can not be accessed because the page's related configuration data invalid is.

wide error
  • error code 0x800700b7
  • notification code
  • notification sender
  • send notification
  • Configuration file
  • Config file
  • The config file '' .svg 'has the unique file attribute set to' File extension with '
  • requested URL http: // Cutting : 14466 / Resources / IMG / Cutting .png
  • Physical Path C : * Erosion * \ resource
  • logon method anonymity
  • Logon user Anonymous
  • Config source:

      58: & lt; MimeMap file extension = ".json" mimeType = "app / jason" /> 59: & lt; MimeMap file extension = ".svg" mimeType = "image / svg + xml" /> 60: & lt; MimeMap file extension = ".woff" mimeType = "application / x-font-woff" />  

    This clearly hates my mimeMap for .svg but it works fine in Azure Websites. Is there anything that locates the web locally? Are you missing to run these changes in config?

    And of course I have already posted my question to find this answer:

    So this problem is that there are already loaded modules in my local IIS configuration, in the meantime the production environment does not. Therefore, to fix the problem for both environments, you need to make sure that mimemaps have been dropped before loading them.

    The following is the code to decide:

      & lt; StaticContent & gt; & Lt; Extract file extension = ".json" /> & Lt; MimeMap file extension = ".json" mimeType = "app / jason" /> & Lt; Extract file extensions = ".svg" /> & Lt; MimeMap file extension = ".svg" mimeType = "image / svg + xml" /> & Lt; Extract file extension = ".woff" /> & Lt; MimeMap file extension = ".woff" mimeType = "app / x-font-woff" /> & Lt; / StaticContent & gt;  

    Hope this helps others waste time looking for fixes.


    Comments

    Popular posts from this blog

    import - Python ImportError: No module named wmi -

    Editing Python Class in Shell and SQLAlchemy -

    c# - MySQL Parameterized Select Query joining tables issue -