1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-18 04:12:00 +02:00

SimplerParse() fix. Db-verify fix for MPREFIX inclusion in xxxx_sql.php files.

This commit is contained in:
Cameron
2012-12-02 17:30:41 -08:00
parent 381053fad5
commit e1ed7b8f6a
3 changed files with 33 additions and 10 deletions

View File

@@ -734,9 +734,12 @@ class e_parse
return preg_replace_callback("#\{([a-zA-Z0-9_]+)\}#", array($this, 'simpleReplace'), $template);
}
protected function simpleReplace($tmp) {
protected function simpleReplace($tmp)
{
$unset = ($this->replaceUnset !== false ? $this->replaceUnset : $tmp[0]);
return ($this->replaceVars->$tmp[1] !== null ? $this->replaceVars->$tmp[1] : $unset);
$key = $tmp[1];
return ($this->replaceVars[$key] !== null ? $this->replaceVars[$key]: $unset);
// return ($this->replaceVars->$tmp[1] !== null ? $this->replaceVars->$tmp[1] : $unset); // Doesn't work.
}
function htmlwrap($str, $width, $break = "\n", $nobreak = "a", $nobr = "pre", $utf = FALSE)