ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
generate-schema-cache.php
Go to the documentation of this file.
1#!/usr/bin/php
2<?php
3
4require_once dirname(__FILE__) . '/common.php';
5require_once dirname(__FILE__) . '/../library/HTMLPurifier.auto.php';
7
22$target = dirname(__FILE__) . '/../library/HTMLPurifier/ConfigSchema/schema.ser';
23
26
27$builder->buildDir($interchange);
28
29$loader = dirname(__FILE__) . '/../config-schema.php';
30if (file_exists($loader)) include $loader;
31foreach ($_SERVER['argv'] as $i => $dir) {
32 if ($i === 0) continue;
33 $builder->buildDir($interchange, realpath($dir));
34}
35
36$interchange->validate();
37
40
41echo "Saving schema... ";
42file_put_contents($target, serialize($schema));
43echo "done!\n";
44
45// vim: et sw=4 sts=4
An exception for terminatinating execution or to throw for unit testing.
Converts HTMLPurifier_ConfigSchema_Interchange to our runtime representation used to perform checks o...
Definition: ConfigSchema.php:8
Generic schema interchange format that can be converted to a runtime representation (HTMLPurifier_Con...
Definition: Interchange.php:9
assertCli()
Definition: common.php:3
if((!isset($_SERVER['DOCUMENT_ROOT'])) OR(empty($_SERVER['DOCUMENT_ROOT']))) $_SERVER['DOCUMENT_ROOT']