mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-08-06 14:16:32 +02:00
[1.3.0] Some housekeeping after the last commit
- Add a few missing unit tests - Allow for spaces between comma separated strings to be transformed into arrays - smoketests/printDefinition.php now has documentation, links to more documentation and a friendly user-interface git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@579 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
@@ -260,7 +260,13 @@ class HTMLPurifier_ConfigSchema {
|
||||
case 'list':
|
||||
case 'hash':
|
||||
case 'lookup':
|
||||
if (is_string($var)) $var = explode(',',$var);
|
||||
if (is_string($var)) {
|
||||
// simplistic string to array method that only works
|
||||
// for simple lists of tag names or alphanumeric characters
|
||||
$var = explode(',',$var);
|
||||
// remove spaces
|
||||
foreach ($var as $i => $j) $var[$i] = trim($j);
|
||||
}
|
||||
if (!is_array($var)) break;
|
||||
$keys = array_keys($var);
|
||||
if ($keys === array_keys($keys)) {
|
||||
|
Reference in New Issue
Block a user