How do I render SVG files in Confluence

How do I get SVG images to render as the image and not the paper clip icon in Confluence 5.8.4?  I followed the details here with no luck, https://bobswift.atlassian.net/wiki/display/info/How+to+display+SVG+attachments+in+Confluence.

Using the HTML Macro works but it we would like it to work through the attachments feature.

 

Any ideas would be very help!

 

Screen Shot 2016-06-29 at 3.08.32 PM.png

 

 

2 answers

1 accepted

We've wanted to do this as well.  However, following the instructions in the article didn't work for us (Confluence Server 5.8.17.  Adding that line to mime.types didn't do the trick for us. (yes, we restarted.))

Last night, we found this trick to make it work:

Upon editing the Confluence Page:
1) Type '!' then select the attached SVG
2) It renders inline
3) Adjust the image size as needed.

Here's a real ugly way to do it.

Embed the SVG code inside an HTML macro.

You wouldn't want to do this way all the time, but it works.

Thanks for the quick response, I forgot to mention that the end user does not want to use the HTML macro feature.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

385 views 21 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you