Same name in other branches
- 5.0.x advagg_js_minify/jspacker.inc \ParseMaster::exec()
- 6.0.x advagg_js_minify/jspacker.inc \ParseMaster::exec()
- 7.x-2.x advagg_js_compress/jspacker.inc \ParseMaster::exec()
- 8.x-2.x advagg_js_minify/jspacker.inc \ParseMaster::exec()
- 8.x-3.x advagg_js_minify/jspacker.inc \ParseMaster::exec()
- 8.x-4.x advagg_js_minify/jspacker.inc \ParseMaster::exec()
Fichier
-
advagg_js_compress/
jspacker.inc, line 617
Classe
Code
public function exec($string) {
// execute the global replacement
$this->_escaped = array();
// simulate the _patterns.toSTring of Dean
$regexp = '/';
foreach ($this->_patterns as $reg) {
$regexp .= '(' . substr($reg[self::EXPRESSION], 1, -1) . ')|';
}
$regexp = substr($regexp, 0, -1) . '/';
$regexp .= $this->ignoreCase ? 'i' : '';
$string = $this->_escape($string, $this->escapeChar);
$string = preg_replace_callback($regexp, array(
&$this,
'_replacement',
), $string);
$string = $this->_unescape($string, $this->escapeChar);
return preg_replace($this->DELETED, '', $string);
}