Request.Files("File1").FileName
Public Function GetFileName(FileAddress)
Dim i
i = InStrRev(FileAddress, "\") + 1
GetFileName = Mid(FileAddress, i)
End Function
Request.Files("File1").SaveAs(MapPath(GetFileName(Request.Files("File1").FileName)))
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<form name="form1" method="post" action="save.asp">
<input type="file" name="file1" runat="server">
<br>
<input type="submit" name="Submit" value="upload">
</form>
</body>
</html>
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<%
Request.file("File1").FileName
Public Function GetFileName(FileAddress)
Dim i
i = InStrRev(FileAddress, "\") + 1
GetFileName = Mid(FileAddress, i)
End Function
Request.File("File1").SaveAs(MapPath(GetFileName(Request.File("File1").FileName)))
%>
<body>
ok
</body>
</html>