diff options
author | Mario Vavti <mario@mariovavti.com> | 2018-01-02 22:14:31 +0100 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2018-01-02 22:14:31 +0100 |
commit | f826c09abc48a522c1a27b44a3fda1e337d90a1a (patch) | |
tree | f53302b072bae510e4d07d72c89b4238614df458 /include/network.php | |
parent | e418a6b3d498cb237bd8f6dd01f40fe57d4a868d (diff) | |
parent | 3bd7133ba32d758df935a566c45515a530b35538 (diff) | |
download | volse-hubzilla-f826c09abc48a522c1a27b44a3fda1e337d90a1a.tar.gz volse-hubzilla-f826c09abc48a522c1a27b44a3fda1e337d90a1a.tar.bz2 volse-hubzilla-f826c09abc48a522c1a27b44a3fda1e337d90a1a.zip |
Merge remote-tracking branch 'mike/master' into dev
Diffstat (limited to 'include/network.php')
-rw-r--r-- | include/network.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/network.php b/include/network.php index 3569874be..79a8c6578 100644 --- a/include/network.php +++ b/include/network.php @@ -752,13 +752,14 @@ function scale_external_images($s, $include_link = true, $scale_replace = false) if($orig_width > 1024 || $orig_height > 1024) { $tag = (($match[1] == 'z') ? 'zmg' : 'img'); + $linktag = (($match[1] == 'z') ? 'zrl' : 'url'); $ph->scaleImage(1024); $new_width = $ph->getWidth(); $new_height = $ph->getHeight(); logger('data: ' . $orig_width . '->' . $new_width . 'w ' . $orig_height . '->' . $new_height . 'h' . ' match: ' . $mtch[0], LOGGER_DEBUG); $s = str_replace($mtch[0],'[' . $tag . '=' . $new_width . 'x' . $new_height. ']' . $scaled . '[/' . $tag . ']' . "\n" . (($include_link) - ? '[zrl=' . $mtch[2] . ']' . t('view full size') . '[/zrl]' . "\n" + ? '[' . $linktag . '=' . $mtch[3] . ']' . t('view full size') . '[/' . $linktag . ']' . "\n" : ''),$s); logger('new string: ' . $s, LOGGER_DEBUG); } |