Closed jurajkapsz closed 8 years ago
I'm curious, does JIT work as expected (aside from this) with SVG's? I would of thought there is fair bit that needs to change to enable SVG as PHP's image_
functions generally don't handle it?
I think only direct
mode works with SVG, that is letting all the images through as they are; but SVG gets the octet mime header.
I am aware of this, I use in this particular case the direct
mode, because I can have also SVG between images in this case.
I have solved this for now by using a real path to the images, but the mime type mentioned above is kind of wrong doing I would say, looks like straight from PHP functions as they are. Maybe it's from the past where browsers did not supported SVG rendering so much, so they were instructed to download it.
We can't support this. SVG cannot be 'jitted'
Please use xsl to check if it's svg and do not pass them to jit.
I would of thought there is fair bit that needs to change to enable SVG as PHP's image_ functions generally don't handle it?
Yes, like, everything.
Not sure what is the https://github.com/symphonycms/jit_image_manipulation/issues/109 issue talking all about, but when a SVG image is ran through a JIT recipe, the SVG image is returned with an
octet-stream
header, but browsers await animage/svg+xml
to display SVG.I guess this is served as it is with native php, probably here class.image.php#L172, but could this be tweaked? As it is no use as it is now, considering SVG images happening to go through a common recipe.