#543 various fixes for SVG in be_thumb and related templates