We have a template which places .gif images like this
https://www.astro.com/im/sym/s_su.18.gif
In the HTML page rendering, it appears as
<img src="https://www.astro.com/im/sym/s_su.18.gif" alt="s_su.18.gif">
I would like to replace the .gif images with .svg images like this:
https://www.astro.com/im/sym/s_su.18.svg
but that is rendered into
<a class="external free" href="https://www.astro.com/im/sym/s_su.18.svg">https://www.astro.com/im/sym/s_su.18.svg</a>
@TheDJ told me that private const EXT_IMAGE_REGEX in Parser.php should be updated.
I patched it to read now
private const EXT_IMAGE_REGEX = '/^(http:\/\/|https:\/\/)((?:\\[(?i:[0-9a-f:.]+)\\])?[^][<>"\\x00-\\x20\\x7F\p{Zs}\x{FFFD}]+) \\/([A-Za-z0-9_.,~%\\-+&;#*?!=()@\\x80-\\xFF]+)\\.((?i)gif|png|jpg|jpeg|svg)$/Sxu';
Now links to of .svg images works.
I also need to update common.css and add
.infobox.toccolours tr td img {width: 18px;}
to get the svg glyphs in the right size.