Skip to Content
author's profile photo Former Member
Former Member

Loading SVG from Portal Application EAR?

Hello there,

we are trying to use SVG images in a portal application.

Unfortunately, I can't get any browser to render them.

I've build a small HTML file, which includes an SVG and a PNG images as well, for comparison.

If I upload these files to a normal web server, like apache, the SVG image gets properly rendered, whereas if loaded from Enterprise Portal, the SVG image is not rendered.

If I compare the requests to the SVG image, the main difference I notice, is the missing response header

Enterprise Portal:

Content-Type: content/unknown

Apache:

Content-Type: image/svg+xml

Can someone help me to get SVG images properly loaded by the browser?

(I am using Enterprise Portal 7.31)

UPDATE:

I was able to get the issue more precise:

If retrieved from KM, the SVG image loads correctly, since I added the mime type in Portal's System Administration -> Knowledge Management -> Utilities -> Mime Types.

But if loaded directly from my Portal Application, mime type is not set and rendering fails.

Is there a way to specify mime types for resources contained in an EAR?

Thanks in advance,

Sascha.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    Posted on Oct 22, 2015 at 05:13 AM

    hi sascha,

    check out this link Managing MIME Types - Administration - SAP Library ; i think you have to add you're MIME type there. give it a try and let me know.

    regards,

    christian

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 21, 2015 at 06:42 PM

    Sascha

    Did you ever find a solution for this?

    I currently have the same issue. I am building a custom masthead, and cant seem to load the svgs.

    Thanks

    Sandip

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.