ASP swfupload 如何获得多个文件名的保存路径?
------------------------------------------------------------------------------------------------------
set upload=new upload_5xsoft
filename=MakeFileName()
set file=upload.file("Filedata")
theFileName = file.FileName
upfileext = getex(theFileName) '得到的文件扩展名
SaveFilePath="/products_pic"&"/"&y&m&"/"& filename & "." & upfileext '用于显示虚拟路径以及完整文件名
SaveFilePath =SaveFilePath &"," &SaveFilePath
DiskFilePath = formPath &"/"& filename & "." & upfileext '文件上传的物理路径以及完整文件名
file.SaveAs DiskFilePath
set file=nothing
set upload=nothing
response.Write SaveFilePath
------------------------------------------------------------------------------------------------------
以上代码只能获得最后上传的一个文件保存路径:
"/products_pic/201105/201152414312732042135.jpg"
请教ASP高手,如何写,才能获得上传的所有文件保存路径,如下效果:
"/products_pic/201105/1.jpg,"/products_pic/201105/2.jpg,/products_pic/201105/3.jpg,
补充:更正,是要获得如下效果:
"/products_pic/201105/1.jpg,/products_pic/201105/2.jpg,/products_pic/201105/3.jpg“
答案:SaveFilePath="/products_pic"&"/"&y&m&"/"& filename & "." & upfileext
SaveFilePath =SaveFilePath &"," &SaveFilePath
改为:
SaveFilePath=SaveFilePath&",/products_pic"&"/"&y&m&"/"& filename & "." & upfileext
上一个:asp.net为什么从svn拿下的项目文件夹没有下面的标签,不能把项目提交到服务器
下一个:ASP.NET中的MENU控件,主菜单后面的小箭头如何去掉?