cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Go to solution

None of my SVG files appear on my site

How do you get svg images to appear? I've added the following .htacess file to my root folder:

 

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

AddType image/svg+xml svg
AddType image/svg+xml svgz
AddEncoding x-gzip .svgz

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

I also tried creating a web.config file with custom MIME types, but with that file, I received an error message when I viewed the web page.

 

For a few weeks, I've been trying to get my svg images with no success.

3 REPLIES 3

Re: None of my SVG files appear on my site

I meant to write, "For a few weeks now, I've been trying to get my svg images to appear with no success."

Re: None of my SVG files appear on my site

Same problem.

Solution

Re: None of my SVG files appear on my site

I had the same problem, also making the same modifications to the .htacess file.

I use the plugin "Safe-Svg " for svg uploads on WP. After installing my svg images showed up.