js获取文章内容中的图片
<Script language="VBScript">
<!--
msgbox getphoto("应明确写出问题所在或关键字<img src=""aaa.gif""/>霸王")
Function getphoto(strHTML)
Dim objRegExp, Match, Matches
Set objRegExp = New Regexp
objRegExp.IgnoreCase = True
objRegExp.Global = True
objRegExp.Pattern = "<img.+?>"
tp=""
Set Matches = objRegExp.Execute(strHTML)
For Each Match in Matches
tp=tp & Match.value
Next
getphoto=tp
Set objRegExp = Nothing
End Function
-->
</script>
时间: 2024-12-24 09:17:35