Last modified: 2010-11-04 17:31:46 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 7645 - Validate SVG content
Validate SVG content
Product: MediaWiki
Classification: Unclassified
File management (Other open bugs)
All All
: Normal enhancement (vote)
: ---
Assigned To: Ariel T. Glenn
Depends on:
Blocks: 3537
  Show dependency treegraph
Reported: 2006-10-20 16:51 UTC by Ruud Steltenpool
Modified: 2010-11-04 17:31 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description Ruud Steltenpool 2006-10-20 16:51:20 UTC
Wikipedia has 16655 pieces of SVG content now (

I bet you quite a bit of that content is not really SVG, valid by the W3C standard.
Please put some QA in place to make all content valid, as otherwise you are
breaking the standard, something that Wikipedia as a proponent of free and easy
exchange of information can't have. has recently started a project like that on which you can build:
Please also help that project improve
Comment 1 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-10-20 20:54:32 UTC
It should be simple to use XMLReader::isValid() for this on upload time, if it
exists (installed by default with PHP 5.1).  The question is what to do if it's
not, outright reject it?  We accept invalid HTML for pages, we just clean it up.

Comment 2 Ruud Steltenpool 2006-10-20 21:54:51 UTC
- Does that XMLreader know how to handle 'extra' namespaces?
 = For example: A significant part of SVG content on the web has been created
with Inkscape of which the default   
   Save results in application specific information being added to the document

- There's more Quality Assurance than just marking something valid or invalid:
 = errors could have suggestions with it, for example:
  # "viewbox" not allowed, "viewBox" allowed though
 = valid content can still get suggestions for improvement:
  # you don't have a viewBox, but you specify a fixed width and height; your
graphic will be more scalable by
    setting width and height to 100% and the viewBox to 0,0,width,height"
  # you use commas in viewBox, replacing them with spaces makes ASV3* correctly
interpret the attribute
    *:Adobe SVG Viewer 3, a deprecated but still significantly used viewer

I just added a link to the source in CVS of the earlier mentioned SVG validation tools
Comment 3 Ruud Steltenpool 2006-10-25 11:13:43 UTC
And with testing the 3rd random thing claiming to be SVG i hit an error:
(not showing an image on Firefox, usually that means not having the right
MIME-type or namespace)
Comment 4 Ruud Steltenpool 2006-10-25 11:20:34 UTC has path elements with
empty d attributes, which is strange to the very least and probably wrong.
Comment 5 Brion Vibber 2009-08-03 16:53:46 UTC
Assigning SVG bugs to Ariel -- need a cleanup pass to see what's fixed up by a librsvg upgrade, what can be resolved with fixes to our font configuration, what can be fixed on our end, and what still needs to be pushed upstream.
Comment 6 Derk-Jan Hartman 2010-11-04 03:40:05 UTC
Seems implemented using XmlTypeCheck atm.

Old files might need re-assesment, which is bugzilla:7645
Comment 7 Bawolff (Brian Wolff) 2010-11-04 17:31:46 UTC
(In reply to comment #6)
> Seems implemented using XmlTypeCheck atm.
> Old files might need re-assesment, which is bugzilla:7645

XmlTypeCheck only checks that the root element is correct (and in the right namespace), and that the xml document is well formed. It doesn't validate that it really is an svg document. (although its unclear from the original request if a well formed-ness check is sufficient).

Note You need to log in before you can comment on or make changes to this bug.