diff options
| author | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-05-21 20:02:43 +0000 |
|---|---|---|
| committer | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-05-21 20:02:43 +0000 |
| commit | 2c1da0d681334a1322d6cbf21ce36079131a3041 (patch) | |
| tree | dfad1fc5807d8895ea667fc490692a91e1981061 | |
| parent | fcf4f542b6f23f0ed14837899c3d923da09c1761 (diff) | |
Make links with /this/ pointing to the plugins skin directory
git-svn-id: https://svn.roundcube.net/trunk@2515 208e9e7b-5314-0410-a742-e7e81cd9613c
| -rwxr-xr-x | roundcubemail/program/include/rcube_template.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/roundcubemail/program/include/rcube_template.php b/roundcubemail/program/include/rcube_template.php index 1a83e5ca3..f6718e337 100755 --- a/roundcubemail/program/include/rcube_template.php +++ b/roundcubemail/program/include/rcube_template.php @@ -357,9 +357,10 @@ class rcube_template extends rcube_html_page return false; } - // replace all path references to plugins/... with the current plugins dir + // replace all path references to plugins/... with the configured plugins dir + // and /this/ to the current plugin skin directory if ($plugin) { - $templ = preg_replace('/\bplugins\//', $this->config['plugins_dir'].'/', $templ); + $templ = preg_replace(array('/\bplugins\//', '/(["\']?)\/this\//'), array($this->config['plugins_dir'].'/', "\\1$skin_path/"), $templ); } // parse for specialtags @@ -374,7 +375,7 @@ class rcube_template extends rcube_html_page ); } $output = $this->parse_with_globals($output); - $this->write(trim($output), $skin_path); + $this->write(trim($output)); if ($exit) { exit; } |
