Copy Code code as follows:
'=====================================
' Get all the pictures in the content
'=====================================
Function get_imgsrc (ByVal t0)
Dim T1,regs,matches,match
T1= ""
IF Not (IsNull (t0) Or Len (t0) =0) Then
Set regs=new REGEXP
Regs.pattern= "]+src=" ([^ ">]+)" "[^>]*>"
Regs.ignorecase=true
Regs.global=true
Set Matches=regs.execute (t0)
IF matches.count>0 Then
For the Match in matches
IF Left (match.submatches (0), 7) <> "http://" Then
t1=t1& "<option value=" "&match.submatches (0) &" ">" &match.submatches (0) & "</option > "
End IF
Next
End IF
End IF
Get_imgsrc=t1
Set matches=nothing
Set regs=nothing
End Function
'=====================================
' Get the first picture in the content
'=====================================
Function frist_pic (ByVal t0)
Frist_pic= ""
Dim regs,matches
Set regs=new REGEXP
Regs.ignorecase=true
Regs.global=true
Regs.pattern= "]+src=" ([^ ">]+)" "[^>]*>"
Set Matches=regs.execute (t0)
IF regs.test (t0) Then
Frist_pic=matches (0). Submatches (0)
End IF
Set matches=nothing
Set regs=nothing
End Function