mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 14:00:31 +02:00
Merge branch 'develop-olympus' into develop
* develop-olympus: [ticket/12202] Use an array in the data provider instead of exploding manually [ticket/12202] Can't call htmlspecialchars before checking for quotes [ticket/12202] Fix tests [ticket/12202] Test for parse_cfg_file [ticket/12202] Use copyright symbol in style.cfg files [ticket/12202] Apply htmlspecialchars to style.cfg data Conflicts: phpBB/styles/prosilver/style.cfg phpBB/styles/subsilver2/style.cfg
This commit is contained in:
@@ -3123,7 +3123,7 @@ function parse_cfg_file($filename, $lines = false)
|
||||
}
|
||||
|
||||
// Determine first occurrence, since in values the equal sign is allowed
|
||||
$key = strtolower(trim(substr($line, 0, $delim_pos)));
|
||||
$key = htmlspecialchars(strtolower(trim(substr($line, 0, $delim_pos))));
|
||||
$value = trim(substr($line, $delim_pos + 1));
|
||||
|
||||
if (in_array($value, array('off', 'false', '0')))
|
||||
@@ -3140,7 +3140,11 @@ function parse_cfg_file($filename, $lines = false)
|
||||
}
|
||||
else if (($value[0] == "'" && $value[sizeof($value) - 1] == "'") || ($value[0] == '"' && $value[sizeof($value) - 1] == '"'))
|
||||
{
|
||||
$value = substr($value, 1, sizeof($value)-2);
|
||||
$value = htmlspecialchars(substr($value, 1, sizeof($value)-2));
|
||||
}
|
||||
else
|
||||
{
|
||||
$value = htmlspecialchars($value);
|
||||
}
|
||||
|
||||
$parsed_items[$key] = $value;
|
||||
|
Reference in New Issue
Block a user