mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-08-06 06:07:26 +02:00
Add support for file:// URI scheme.
Signed-off-by: Edward Z. Yang <ezyang@mit.edu>
This commit is contained in:
5
tests/HTMLPurifier/HTMLT/file-uri.htmlt
Normal file
5
tests/HTMLPurifier/HTMLT/file-uri.htmlt
Normal file
@@ -0,0 +1,5 @@
|
||||
--INI--
|
||||
URI.AllowedSchemes = file
|
||||
--HTML--
|
||||
<a href="file:///foo">foo</a>
|
||||
--# vim: et sw=4 sts=4
|
@@ -165,6 +165,13 @@ class HTMLPurifier_URISchemeTest extends HTMLPurifier_URIHarness
|
||||
);
|
||||
}
|
||||
|
||||
function test_file_basic() {
|
||||
$this->assertValidation(
|
||||
'file://user@MYCOMPUTER:12/foo/bar?baz#frag',
|
||||
'file://MYCOMPUTER/foo/bar#frag'
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// vim: et sw=4 sts=4
|
||||
|
Reference in New Issue
Block a user