EEVblog > News/Suggestions/Help

Adding .svg to allowed attachment file types?

(1/7) > >>

Nominal Animal:
Would it be possible to add .svg to the allowed upload attachment file suffix list?
I do not think it is necessary to add any extensions to the SimpleMachines Forum software, just add the file suffix to the allowed suffixes' list.

Current browsers support SVG files just like PNG, GIF, and JPEG images.  SimpleMachines Forum also supports SVG images; it just does not allow uploading .svg files as an attachment.

Consider Larry Ewing's classix Tux logo, a 94015 byte SVG file:

which is displayed above using [img]https://www.nominal-animal.net/answers/tux-by-larry-ewing.svg[/img] .

(If one removes the width and height attributes of the target SVG file SVG element, only leaving the viewBox attribute, the SVG image will naturally scale to the maximum size possible in the allowed space, see e.g. https://www.nominal-animal.net/answers/tux-by-larry-ewing-unsized.svg.)

Inkscape is an easy to learn application for creating, editing, and manipulating SVG files, and is freely available for basically all operating systems, but all vector graphics packages nowadays do support SVG.

Diagrams, including circuit diagrams, are better described in vector graphics formats like SVG: file size should be smaller, and visual fidelity much better.  Many free web tools like EasyEDA do allow easy export in SVG form, too.

I myself put the images on my own web site, and just link to them (as shown above), but I think it would make sense to allow SVG file uploads as normal image attachments, too.  It would help with both image fidelity and file size (using less server resources).

emece67:
.

Berni:
I agree the SVG format is one of the best vector graphics formats out there. It is well supported by software, does not break so easily from one software to the next, no huge amounts of legacy baggage, no big corporation pushing the format.

The only other widely usable way to send vector graphics is PDF but i had that go wrong in so many ways.

magic:

--- Quote from: Nominal Animal on February 23, 2022, 04:48:23 am ---Consider Larry Ewing's classix Tux logo, a 94015 byte SVG file:
--- End quote ---
:scared:


--- Quote from: Nominal Animal on February 23, 2022, 04:48:23 am ---Diagrams, including circuit diagrams, are better described in vector graphics formats like SVG: file size should be smaller

--- End quote ---
April Fools is next month ;)


I don't necessarily disagree with the proposal, but you picked a wrong example, perhaps.

Ian.M:
Unfortunately allowing SVG files without a robust server side SVG validator and malware scanner would permit cross-site scripting attacks to be hosted at EEVblog, so its not as simple as just adding .svg to the permitted extension list.

See: https://www.fortinet.com/blog/threat-research/scalable-vector-graphics-attack-surface-anatomy

Navigation

[0] Message Index

[#] Next page

There was an error while thanking
Thanking...
Go to full version