28,404
社区成员
发帖
与我相关
我的任务
分享
<a href="/ShowArticle.asp?ArticleID=743">链接1</a>
<a href="/ShowArticle.asp?ArticleID=654">链接2</a>
<a href="/ShowArticle.asp?ArticleID=325">链接3</a>
<a href="/ShowArticle.asp?ArticleID=72">链接4</a>
<a href="/ShowArticle.asp?ArticleID=7563">链接5</a>

s = "<a href=""/ShowArticle.asp?ArticleID=743"">链接1</a>" & VbCrLf &_
"<a href=""/ShowArticle.asp?ArticleID=654"">链接2</a>" & VbCrLf &_
"<a href=""/ShowArticle.asp?ArticleID=325"">链接3</a>" & VbCrLf &_
"<a href=""/ShowArticle.asp?ArticleID=72"">链接4</a>" & VbCrLf &_
"<a href=""/ShowArticle.asp?ArticleID=7563"">链接5</a>"
Set re = New RegExp
With re
.Global = True
.IgnoreCase = True
.MultiLine = True
.Pattern = "href=""([^""]+=(\d+))"""
s = .Replace(s, "href=""/info$2.html""")
End With
Response.Write s