Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
<img([^>]*)src="[(([^:"]*)({png|gif|jpg|jpeg}))]"
/
img
Input 1
New
<!DOCTYPE html> <html> <body> <img src="smiley.gif" alt="Smiley face" height="42" width="42" style="float:right"> <p>Insert an image from another folder:</p> <img src="/images/stickman.gif" alt="Stickman" width="24" height="39"> <p style="float:left">Insert an image from a web site:</p> <img style="color:green; float:right;" src="http://www.w3schools.com/images/lamp.gif" alt="Lamp" width="15" height="15"> </body> </html>
Extraction
<!DOCTYPE html> <html> <body> <img src="smiley.gif" alt="Smiley face" height="42" width="42" style="float:right"> <p>Insert an image from another folder:</p> <img src="/images/stickman.gif" alt="Stickman" width="24" height="39"> <p style="float:left">Insert an image from a web site:</p> <img style="color:green; float:right;" src="http://www.w3schools.com/images/lamp.gif" alt="Lamp" width="15" height="15"> </body> </html>