I'm using the Pure ASP upload script provided on
I've got the script to work in that it picks up the filename/type and size to the confirmation screen, which also submits other data from the form to a database. However, it doesn't actually upload the file, which defeats the object somewhat!
The first portion of script is as follows - anyone got any idea where the problem lies? Thanks in advance:
<!-- #include file="upload.asp" -->
<%
' Create the FileUploader
Dim Uploader, File
Set Uploader = New FileUploader
' This starts the upload process
Uploader.Upload()
' Check if any files were uploaded
If Uploader.Files.Count = 0 Then
Response.Write "File not uploaded."
Else
' Loop through the uploaded files
For Each File In Uploader.Files.Items
' Save the file
File.SaveToDisk "C:\Documents and Settings\walderrm\My Documents\"" & File.FileName & """
' Output the file details to the browser
Filename = "" & File.FileName & ""
FileSize = "" & File.FileSize & ""
FileContentType = "" & File.ContentType & ""
AddDocPath = ""& File.FileName &""
Next
End If
%>
<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<%If type_of_submit = "Amend" then
Response.Write "<title>Update Successful</title>"
else
Response.Write "<title>Upload Successful</title>"
end If
%>
<style TYPE="text/css"><!--A { text-decoration: none }A:hover { color:Red}--></style>
<title>Success!</title>
<meta name="Microsoft Theme" content="apo-blue 1000, default">
</head>
<body topmargin="0" leftmargin="0">
<%
AddIDNumber = Uploader.Form("AddIDNumber"
AddDocTitle = Uploader.Form("AddDocTitle"
AddApprover = Uploader.Form("AddApprover"
IDNumber = Uploader.Form("IDNumber"
DocTitle = Uploader.Form("DocTitle"
DocPath = Uploader.Form("DocPath"
Approver = Uploader.Form("Approver"
SeqNumber = Uploader.Form("SeqNumber"
I've got the script to work in that it picks up the filename/type and size to the confirmation screen, which also submits other data from the form to a database. However, it doesn't actually upload the file, which defeats the object somewhat!
The first portion of script is as follows - anyone got any idea where the problem lies? Thanks in advance:
<!-- #include file="upload.asp" -->
<%
' Create the FileUploader
Dim Uploader, File
Set Uploader = New FileUploader
' This starts the upload process
Uploader.Upload()
' Check if any files were uploaded
If Uploader.Files.Count = 0 Then
Response.Write "File not uploaded."
Else
' Loop through the uploaded files
For Each File In Uploader.Files.Items
' Save the file
File.SaveToDisk "C:\Documents and Settings\walderrm\My Documents\"" & File.FileName & """
' Output the file details to the browser
Filename = "" & File.FileName & ""
FileSize = "" & File.FileSize & ""
FileContentType = "" & File.ContentType & ""
AddDocPath = ""& File.FileName &""
Next
End If
%>
<html>
<head>
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<%If type_of_submit = "Amend" then
Response.Write "<title>Update Successful</title>"
else
Response.Write "<title>Upload Successful</title>"
end If
%>
<style TYPE="text/css"><!--A { text-decoration: none }A:hover { color:Red}--></style>
<title>Success!</title>
<meta name="Microsoft Theme" content="apo-blue 1000, default">
</head>
<body topmargin="0" leftmargin="0">
<%
AddIDNumber = Uploader.Form("AddIDNumber"
AddDocTitle = Uploader.Form("AddDocTitle"
AddApprover = Uploader.Form("AddApprover"
IDNumber = Uploader.Form("IDNumber"
DocTitle = Uploader.Form("DocTitle"
DocPath = Uploader.Form("DocPath"
Approver = Uploader.Form("Approver"
SeqNumber = Uploader.Form("SeqNumber"