Viewing SVG and other HTML5 content on IIS webserver on localhost in Asp.Net
09 Jun 2015
Kamal Pratap
Comments
2622
Views
Sometime SVG and HTML5 Content not working in asp.net so we configure the Web.config to solve this problem. User this code an put in the Web.config.
Web.Config :
<system.webServer>
<!-- START OF BLOCK TO INSERT -->
<staticContent>
<mimeMap fileExtension=".mp4" mimeType="video/mp4" />
<mimeMap fileExtension=".m4v" mimeType="video/m4v" />
<mimeMap fileExtension=".ogg" mimeType="video/ogg" />
<mimeMap fileExtension=".ogv" mimeType="video/ogg" />
<mimeMap fileExtension=".oga" mimeType="audio/ogg" />
<mimeMap fileExtension=".spx" mimeType="audio/ogg" />
<mimeMap fileExtension=".svg" mimeType="images/svg+xml" />
<mimeMap fileExtension=".svgz" mimeType="images/svg+xml" />
<remove fileExtension=".eot" />
<mimeMap fileExtension=".eot" mimeType="application/vnd.ms-fontobject" />
<mimeMap fileExtension=".otf" mimeType="font/otf" />
<mimeMap fileExtension=".woff" mimeType="font/x-woff" />
<mimeMap fileExtension=".appcache" mimeType="text/cache-manifest" />
</staticContent>
<!-- END OF BLOCK TO INSERT -->
</system.webServer>