发表一个删除用编辑器添加内容中图片的东东
如题:<% function fd(str)
bb=split(str,"<img")
for i=0 to ubound(bb)
cc=bb(i)
bc=split(cc," ")
for j=0 to ubound(bc)
bj=bc(j)
if instr(bj,"=")<>0 then
bk=split(bj,"=")
if instr(bk(1),".gif")<>0 or instr(bk(1),".jpg")<>0 or instr(bk(1),".bmp")<>0 then
fd=fd&replace(bk(1),"""","")&"|"
end if
end if
next
next
end function %>
fdimg=fd(rs("con"))
set fso=server.CreateObject("scripting.filesystemobject")
if fdimg<>"" and instr(fdimg,"|")<>0 then
fimg=split(fdimg,"|")
for b=0 to ubound(fimg)-1
if fso.fileexists(fm)=true then
fso.deletefile fm
end if
next
end if