mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-07-31 03:10:09 +02:00
Commit initial URI unit tests and implementation. They're not complete yet though.
git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@206 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
23
library/HTMLPurifier/URISchemeRegistry.php
Normal file
23
library/HTMLPurifier/URISchemeRegistry.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
class HTMLPurifier_URISchemeRegistry
|
||||
{
|
||||
|
||||
// pass a registry object $prototype with a compatible interface and
|
||||
// the function will copy it and return it all further times.
|
||||
// pass bool true to reset to the default registry
|
||||
function &instance($prototype = null) {
|
||||
static $instance = null;
|
||||
if ($prototype !== null) {
|
||||
$instance = $prototype;
|
||||
} elseif ($instance === null || $prototype == true) {
|
||||
$instance = new HTMLPurifier_URISchemeRegistry();
|
||||
}
|
||||
return $instance;
|
||||
}
|
||||
|
||||
function &getScheme($scheme) {}
|
||||
|
||||
}
|
||||
|
||||
?>
|
Reference in New Issue
Block a user