<!--#include file="../../../inc/cms_class.asp"-->
<%
dim remotestr,remotepic,remotesplit,j,newpath,newpicname,newimg,newimgs,upfolder,parentPath
upfolder=getform("upfolder","both")
if isnul(upfolder) then
 parentPath=sitepath&upLoadPath
else
 parentPath=sitepath&upLoadPath&upfolder&"/"
end if
	remotestr =Trim(Request("file"))
	remotestr=replace(remotestr,"&amp;" , "&")
	remotestr=remotestr
	remotestr=remotestr&"ue_separate_ue"
	remotesplit=split(remotestr,"ue_separate_ue")
	newpath=parentPath&DateFormat(now,"yymmdd")&"/"
	NewFolder newpath
for j=0 to ubound(remotesplit)-1
	newpicname=getrndname()&"."&GetFileExt(remotesplit(j))	
	newimg=SaveRemoteFile(newpath&newpicname,remotesplit(j))
	if waterMark=1 then waterMarkImg newimg
	newimgs=newimgs&newimg&"ue_separate_ue"
next
  remotestr=endstr(remotestr,"ue_separate_ue")
  echo "{'url':'"&newimgs&"','tip':'远程图片抓取成功！','srcUrl':'"&remotestr& "'}"
%>