summaryrefslogtreecommitdiff
path: root/roundcubemail/program/steps
diff options
context:
space:
mode:
authoralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2012-01-05 09:51:41 +0000
committeralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2012-01-05 09:51:41 +0000
commit869b31cb77d2d2eff55e298df0ed99734aa227e2 (patch)
treee318e2b75e38ad2fb83eea1dd2ae5487c9b26bf8 /roundcubemail/program/steps
parent748f497cb09fccb1eeff25b0bc41f69b44bc0f5c (diff)
- Fix bug in handling of base href and inline content (#1488290)
git-svn-id: https://svn.roundcube.net/trunk@5713 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/steps')
-rw-r--r--roundcubemail/program/steps/mail/func.inc6
1 files changed, 2 insertions, 4 deletions
diff --git a/roundcubemail/program/steps/mail/func.inc b/roundcubemail/program/steps/mail/func.inc
index 3784456c7..f791f7033 100644
--- a/roundcubemail/program/steps/mail/func.inc
+++ b/roundcubemail/program/steps/mail/func.inc
@@ -1110,15 +1110,13 @@ function rcmail_resolve_base($body)
// check for <base href=...>
if (preg_match('!(<base.*href=["\']?)([hftps]{3,5}://[a-z0-9/.%-]+)!i', $body, $regs)) {
$replacer = new rcube_base_replacer($regs[2]);
-
- // replace all relative paths
- $body = preg_replace_callback('/(src|background|href)=(["\']?)([^"\'\s]+)(\2|\s|>)/Ui', array($replacer, 'callback'), $body);
- $body = preg_replace_callback('/(url\s*\()(["\']?)([^"\'\)\s]+)(\2)\)/Ui', array($replacer, 'callback'), $body);
+ $body = $replacer->replace($body);
}
return $body;
}
+
/**
* modify a HTML message that it can be displayed inside a HTML page
*/