jcuenin Posted July 18, 2016 Share Posted July 18, 2016 Hello, I need to use svg images as category thumbnails and would like to know if there is a way to do so? When i tried to upload the svg image, Prestashop gave me this error : Unknown image format : accepted format : GIF, JPG, PNG I checked and it seems that the SVG format is activated in the Prestashop file manager, so why do I get an error message? Thank you in advance for your help, Best regards, Julien Link to comment Share on other sites More sharing options...
rocky Posted July 21, 2016 Share Posted July 21, 2016 PrestaShop doesn't support SVG for categories, products, manufacturers, etc. You'll need to override the image links in category.tpl with your own links. For example, {$img_dir}svg/{$category.id_category}.svg{/if} if you want to create a themes/<your_theme>/img/svg/ subdirectory and put all the category SVGs in there. Link to comment Share on other sites More sharing options...
vekia Posted July 21, 2016 Share Posted July 21, 2016 im affraid that prestashop will not generate thumbs from svg file. it's because, simply saying, GD in php does not support .svg files. Link to comment Share on other sites More sharing options...
jcuenin Posted July 22, 2016 Author Share Posted July 22, 2016 Hello, Thank you for your answers. Rocky, yes this is what I ended up doing but in a module. I just wanted to find a way for the client to upload the files easily instead of using ftp but that's not possible. Vekia, ok I understand better now. The weird thing though is that I can upload a svg file in a cms page without any problems. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now