SVG in Media Library?

James Jarrett asked on July 15, 2014 16:08

Does the Media Library support SVG files?

I added .svg to the Media Content allowed under the Settings tab and I was able to add the file to the Media Library. However I am getting a 404 error when I try to view the file. It occurred to me Media Library items are probably being saved as binary data and svg is text.

Recent Answers


Eric Garrison answered on July 15, 2014 17:50

I have never tired adding .SVG to the media library, but to use them in design, I had to add the mime-type to IIS in the Web.config:

0 votesVote for this answer Mark as a Correct answer

Eric Garrison answered on July 15, 2014 17:51

 Sorry, the editor stripped my sample

 <code> </handlers>
    <staticContent>
      <remove fileExtension=".woff" />
      <mimeMap fileExtension=".woff" mimeType="application/x-font-woff" />
      <remove fileExtension=".svg" />
      <mimeMap fileExtension=".svg" mimeType="image/svg+xml" />
    </staticContent> </code>
0 votesVote for this answer Mark as a Correct answer

Jon Tetzlaff answered on August 10, 2015 17:06

You can add SVG to the media library by adding the extension in the settings app, but they won't work with the media selector. Kentico doesn't set the proper mime type when serving a svg from the media library.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.