Microsoft VBScript 运行时错误 '800a01fa' |
Microsoft VBScript 运行时错误 '800a01fa'
类没有被定义: 'upload_5xSoft'
\wwwroot\admin\Manage_upfile.asp, line 4 以下是页面的代码 <!--#include FILE="Manage_upload.inc"--> <% dim upload,file,formName,formPath,iCount,200831003759.asp,fileExt set upload=new upload_5xSoft ''建立上传对象 formPath="images/upfile/" ''在目录后加(/) if right(formPath,1)<>"/" then formPath=formPath&"/" iCount=0 for each formName in upload.file ''列出所有上传了的文件 set file=upload.file(formName) ''生成一个文件对象 if file.filesize<100 then response.write "<font size=2>请先选择你要上传的图片 [ <a href=# onclick=history.go(-1)>重新上传</a> ]</font>" response.end end if
if file.filesize>3000000000 then response.write "<font size=2>图片大小超过了限制 [ <a href=# onclick=history.go(-1)>重新上传</a> ]</font>" response.end end if
fileExt=lcase(right(file.200831003759.asp,4))
if fileEXT<>".gif" and fileEXT<>".jpg" and fileEXT<>".jpeg" and fileEXT<>".bmp" then response.write "<font size=2>文件格式不对 [ <a href=# onclick=history.go(-1)>重新上传</a> ]</font>" response.end end if randomize ranNum=int(90000*rnd)+10000 200831003759.asp=formPath&year(now)&month(now)&day(now)&hour(now)&minute(now)&second(now)&fileExt 200831003759.asp1=year(now)&month(now)&day(now)&hour(now)&minute(now)&second(now)&fileExt
if file.FileSize>0 then ''如果 FileSize > 0 说明有文件数据 file.SaveAs Server.mappath(200831003759.asp) ''保存文件 response.write "<script>parent.form1.upfile.value+='"&"images/upfile/"&FileName1&"'</script>" iCount=iCount+1 end if set file=nothing next set upload=nothing ''删除此对象
response.write "图片上传成功" response.end
%> </body> </html>
问题补充:我已经解决了,把代码的头部和尾部换成<% %>就ok了
如果用的netbox做服务,很正常,他不支持runat=server这种方式的服务端脚本 (编辑:网站学习网)
|
|
|
|