alchemy-fr / PHP-dataURI

A PHP dataURI library, RFC 2397 Compliant
Other
59 stars 25 forks source link

adjusting the parser and adding tests for formats with dots and pluses (... #4

Closed joaoprp closed 10 years ago

joaoprp commented 10 years ago

...such as the ones in the test)

Following everything who I've read in the other pull request, adding the tests and adding an extra character (the plus sign), who allows to parse svg docs as well (image/svg+xml).

nlegoff commented 10 years ago

Thanks @joaoprp

romainneutron commented 10 years ago

Please update changelog and tag a version

DQNEO commented 8 years ago

I am afraid this is not correct and no tests are added actually.

For example, this test fails.

        $dataURI = DataURI\Parser::parse($tests[4]);
        $this->assertEquals('image/svg+xml', $dataURI->getMimeType());

Parser parses image/svg+xml as image/svg.