Regular Expressions 101

Community Patterns

get img src from html

0

Regular Expression
Python

r"
<img\s+[\S\"'= ]{0,40}src=[\"'](?P<src>(http(s)?:)?\/\/[^\":>]+)[\"']?
"
gm

Description

match the src attribute of the html img tag

Submitted by anonymous - 5 years ago