在form中加了enctype=multipart/form-data,text的值就取不出来了,怎么解决啊,谢谢
<!--#include file="conn.asp"--><!--#include file="upload_inc.asp"-->
<%
'上传图片*********************************************************
IDstring=session("id")&date & time '图片文件名
IDstring=Replace(IDstring,"-","")
IDstring=Replace(IDstring,":","")
pthString="gg_images/"
set upload=new upload_5xsoft
imgLink=replace(trim(upload.Form("imgLink")),"'","’")
set file=upload.file("imgUrl")
if file.filesize>0 then
if file.filesize>2097152 then
set file=nothing
response.write("<script>alert('上传图片的大小不能大于2M,即:2097152字节!');history.back(1);</script>")
else
FileTpe=Mid(file.filename,Len(file.filename)-2)
if not (ucase(fileTpe)="JPG" or ucase(fileTpe)="BMP" or ucase(fileTpe)="GIF") then
response.write("<script>alert('上传图片格式只能为:JPG,BMP,GIF。');history.back(1);</script>")
else
file.saveAs Server.mappath(pthString & IDstring & "." & FileTpe)
filepath=IDstring & "." & FileTpe
end if
end if
else
filepath=""
end if
set file=nothing
'上传结束*********************************************************
set rs=server.createobject("adodb.recordset")
rs.open "select * from [gg_pic]",conn,1,3
rs.addnew
rs("imgUrl")=filepath
rs("imgLink")=imgLink
rs.update
rs.close
set rs=nothing
set upload=nothing
response.Write "<script language=javascript>alert('添加成功!');window.location.href='admin_gg_edit.asp'</script>"
%>
图片可以上传,文件名可以取得,就是imgLink=replace(trim(upload.Form("imgLink")),"'","’")的值取不到,麻烦指点一下,谢谢了