mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-08-08 07:06:46 +02:00
[3.1.0] Further cleanup, making standalone work again
- Remove includes call in HTMLPurifier.auto.php - Relax ConfigSchema treatment in generate-includes.php - Clean up some empty comments (there are probably more) - De-indent some extends - class_exists() should now attempt to use autoload - schema.ser is now a standalone file - tests/index.php can be run from any directory git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@1540 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
@@ -18,13 +18,11 @@ $FS = new FSTools();
|
||||
$exclude_dirs = array(
|
||||
'HTMLPurifier/Language/',
|
||||
'HTMLPurifier/Filter/',
|
||||
'HTMLPurifier/ConfigDef/', // specially handled, remove this once fixed!
|
||||
);
|
||||
$exclude_files = array(
|
||||
'HTMLPurifier/Lexer/PEARSax3.php',
|
||||
'HTMLPurifier/Lexer/PH5P.php',
|
||||
'HTMLPurifier/Bootstrap.php',
|
||||
'HTMLPurifier/ConfigDef.php', // specially handled, remove this once fixed!
|
||||
);
|
||||
|
||||
// Determine what files need to be included:
|
||||
@@ -65,9 +63,6 @@ function get_dependency_lookup($file) {
|
||||
$deps = array();
|
||||
while (!feof($fh)) {
|
||||
$line = fgets($fh);
|
||||
if (strncmp('HTMLPurifier_ConfigSchema', $line, 25) === 0) {
|
||||
$deps['HTMLPurifier/ConfigSchema.php'] = true;
|
||||
}
|
||||
if (strncmp('class', $line, 5) === 0) {
|
||||
// The implementation here is fragile and will break if we attempt
|
||||
// to use interfaces. Beware!
|
||||
|
@@ -145,6 +145,7 @@ $FS->rmdirr('standalone'); // ensure a clean copy
|
||||
// data files
|
||||
$FS->mkdirr('standalone/HTMLPurifier/DefinitionCache/Serializer');
|
||||
make_dir_standalone('HTMLPurifier/EntityLookup');
|
||||
make_file_standalone('HTMLPurifier/ConfigSchema/schema.ser');
|
||||
|
||||
// non-standard inclusion setup
|
||||
make_dir_standalone('HTMLPurifier/Language');
|
||||
|
Reference in New Issue
Block a user