Skip to content

Commit 588a0e3

Browse files
committed
adding more img tags
Signed-off-by:Heesung Ahn <ahn.heesung@gmail.com>
1 parent 7b0e60b commit 588a0e3

1 file changed

Lines changed: 14 additions & 2 deletions

File tree

tests/codeigniter/core/Security_test.php

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,24 @@ public function test_strip_image_tags()
133133
{
134134
$imgtags = Array(
135135
'<img src="smiley.gif" alt="Smiley face" height="42" width="42">',
136-
'<img src="http://www.w3schools.com/images/w3schools_green.jpg">'
136+
'<img alt="Smiley face" height="42" width="42" src="smiley.gif">',
137+
'<img src="http://www.w3schools.com/images/w3schools_green.jpg">',
138+
'<img src="/img/sunset.gif" height="100%" width="100%">',
139+
'<img src="mdn-logo-sm.png" alt="MD Logo" srcset="mdn-logo-HD.png 2x, mdn-logo-small.png 15w, mdn-banner-HD.png 100w 2x" />',
140+
'<img sqrc="/img/sunset.gif" height="100%" width="100%">',
141+
'<img srqc="/img/sunset.gif" height="100%" width="100%">',
142+
'<img srcq="/img/sunset.gif" height="100%" width="100%">'
137143
);
138144

139145
$urls = Array(
140146
'smiley.gif',
141-
'http://www.w3schools.com/images/w3schools_green.jpg'
147+
'smiley.gif',
148+
'http://www.w3schools.com/images/w3schools_green.jpg',
149+
'/img/sunset.gif',
150+
'mdn-logo-sm.png',
151+
'<img sqrc="/img/sunset.gif" height="100%" width="100%">',
152+
'<img srqc="/img/sunset.gif" height="100%" width="100%">',
153+
'<img srcq="/img/sunset.gif" height="100%" width="100%">'
142154
);
143155

144156
for($i = 0; $i < count($imgtags); $i++)

0 commit comments

Comments
 (0)