|
@@ -154,7 +154,7 @@ discard block |
|
|
block discarded – undo |
|
154
|
154
|
foreach ($attachments[0] as $attachmentURL) { |
|
155
|
155
|
$start = mb_strpos($attachmentURL, '/'); |
|
156
|
156
|
$end = mb_strrpos($attachmentURL, '"'); |
|
157
|
|
- $fileName = mb_substr($attachmentURL, $start + 1, $end - ($start + 1)); |
|
|
157
|
+ $fileName = mb_substr($attachmentURL, $start+1, $end-($start+1)); |
|
158
|
158
|
|
|
159
|
159
|
if (method_exists($this->article, 'getAttachmentSecureURL')) { |
|
160
|
160
|
$this->content = str_replace($attachmentURL, 'href='.$this->article->getAttachmentSecureURL($fileName), $this->content); |
|
@@ -168,7 +168,7 @@ discard block |
|
|
block discarded – undo |
|
168
|
168
|
foreach ($attachments[0] as $attachmentURL) { |
|
169
|
169
|
$start = mb_strpos($attachmentURL, '/'); |
|
170
|
170
|
$end = mb_strrpos($attachmentURL, '" alt'); |
|
171
|
|
- $fileName = mb_substr($attachmentURL, $start + 1, $end - ($start + 1)); |
|
|
171
|
+ $fileName = mb_substr($attachmentURL, $start+1, $end-($start+1)); |
|
172
|
172
|
|
|
173
|
173
|
if ($config->get('cms.images.widget')) { |
|
174
|
174
|
// get the details of the source image |
|
@@ -183,7 +183,7 @@ discard block |
|
|
block discarded – undo |
|
183
|
183
|
$type = 'png'; |
|
184
|
184
|
} |
|
185
|
185
|
|
|
186
|
|
- $img = new Image($path, $image_details[0], $image_details[1], $type, 0.95, false, (boolean) $config->get('cms.images.widget.secure')); |
|
|
186
|
+ $img = new Image($path, $image_details[0], $image_details[1], $type, 0.95, false, (boolean)$config->get('cms.images.widget.secure')); |
|
187
|
187
|
$this->content = str_replace($attachmentURL, $img->renderHTMLLink(), $this->content); |
|
188
|
188
|
} else { |
|
189
|
189
|
// render a normal image link to the ViewAttachment controller |