Use SVG in Windows Azure Websites

cmplieger picture cmplieger · Aug 7, 2012 · Viewed 12.7k times · Source

Does anyone know if it is possible to add the SVG mime type to a Windows Azure Website? I tried with a web.config file but that only broke my website.

Is this a limitation of the current preview or am I missing something?

thanks for your help!

Answer

Sandrino Di Mattia picture Sandrino Di Mattia · Aug 7, 2012

What you can do in Windows Azure Websites (on web.config level) is pretty limited, but you should be allowed to add the mime type under staticContent:

<configuration>
   <system.webServer>
      <staticContent>
         <remove fileExtension=".svg"/>
         <mimeMap fileExtension=".svg" mimeType="image/svg+xml" />
      </staticContent>
   </system.webServer>
</configuration>