我想提取在data-src后面的地址,始终把data-src也提取出来了
这样就行
import re html_str = 'AAAAAdata-src=123' local = re.findall(r'data-src=(.*)', html_str) print(local[0])