Skip to content

Commit 2095258

Browse files
committed
Merge pull request bcit-ci#2934 from wuwx/patch-3
Check image path is include http:// or https://
2 parents fde170c + bcb6b8e commit 2095258

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

system/helpers/html_helper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ function img($src = '', $index_page = FALSE, $attributes = '')
181181

182182
foreach ($src as $k => $v)
183183
{
184-
if ($k === 'src' && strpos($v, '://') === FALSE)
184+
if ($k === 'src' && ! preg_match('#^https?://#i', $v))
185185
{
186186
if ($index_page === TRUE)
187187
{

0 commit comments

Comments
 (0)