Commit 6478762b authored by BjoernE's avatar BjoernE 👨‍👩‍👧‍👦
Browse files

[#38] merged mosaico relative url fix (dev_38)

parents 8aeaa312 20140a0d
......@@ -112,6 +112,11 @@ function civiproxy_mend_URLs(&$string) {
}
if ($target_file) {
$string = preg_replace("#{$target_file}#", $proxy_base . '/file.php?id=', $string);
// https://github.com/systopia/CiviProxy/issues/38
// fix for relative
if ($target_mosaico) {
$string = preg_replace("#src=\"\/sites\/default\/files\/civicrm\/persist\/#", 'src="' . $proxy_base . '/file.php?id=', $string);
}
}
if ($target_mosaico) {
// replace full, and relative URL
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment