thomascube
2012-01-27 f6a7491fa1332d43ac7167d50472aa514fd0caf2
Fix special vars replacement in templates

2 files modified
2 ■■■ changed files
program/include/rcube_html_page.php 1 ●●●● patch | view | raw | blame | history
program/include/rcube_template.php 1 ●●●● patch | view | raw | blame | history
program/include/rcube_html_page.php
@@ -284,7 +284,6 @@
        $output = preg_replace_callback(
            '!(src|href|background)=(["\']?)([a-z0-9/_.-]+)(["\'\s>])!i',
            array($this, 'file_callback'), $output);
        $output = str_replace('$__skin_path', $base_path, $output);
        // trigger hook with final HTML content to be sent
        $hook = rcmail::get_instance()->plugins->exec_hook("send_page", array('content' => $output));
program/include/rcube_template.php
@@ -528,6 +528,7 @@
    {
        $GLOBALS['__version'] = Q(RCMAIL_VERSION);
        $GLOBALS['__comm_path'] = Q($this->app->comm_path);
        $GLOBALS['__skin_path'] = Q($this->config['skin_path']);
        return preg_replace_callback('/\$(__[a-z0-9_\-]+)/',
        array($this, 'globals_callback'), $input);
    }