The purpose of my code is to allow a user to navigate to a (Folderview)folder, select "Upload" from a side menu and then allow them to upload a 10MB +/- to that folder. I set out to capture the path of the folder the user is in and then proceeded to send it to a second page where the user can choose a file to upload to that folder.
I pass the folder path as a renamed variable to a Persists Upload page (Because of the file size limitations in IIS 6.0 I found I can't use Binary. The only problem is I can't get the file to upload using the variable path I captured by using Upload.Save or Upload.SaveVirtual.
When I pass the path the first time I can view the variable but when I try to send it the second time through a hidden value using a second form, it won't pass. I know that I am getting the value to the second form successfully(I checked). I am using a Hidden Input Value to hold it.
I checked to see if the hidden value was retaining the variable correctly and it is. It just won't pass from the second form to the FORM ACTION page. I have the code below. I hope I included all of the relevant parts. Also, I am able to upload using standard paths (C:\*)
--------------------------------------------------------
ReCap of Goal
User goes to folder | Clicks Upload | Page appears to select file to upload | User Chooses File & Clicks Upload | File Uploads
-------------------------------------------------------
1) I passed the value of my First Form to my second form page. I received it and then renamed the variable before sending it on to my Upload form.
<% Dim Strpass
StrPass = request.form("Direct")%>
2) I passed the value to my Hidden Input
<FORM METHOD="POST" ENCTYPE="multipart/form-data" ACTION="Upload.asp">
<INPUT TYPE=FILE SIZE=60 NAME="FILE1"><BR>
<INPUT TYPE=HIDDEN Value="<%=StrPass%>" Name="PATH">
<INPUT TYPE=SUBMIT VALUE="Upload!">
</FORM>
3) My upload.asp page either gets error 500 (No friendly error showing)or acts like it worked (or Uploaded) and the file is not uploaded.
(upload.asp code below)
<%Response.Buffer = False
Dim NewPath
NewPath = request.form("Path")
Set Upload = Server.CreateObject("Persits.Upload.1")
Count = Upload.SaveVirtual(NewPath)%>
<%= Count %> files were uploaded
Please let me know if I need to list more code. I tried to put the main parts for what I am trying to accomplish. Any help is greatly appreciated. I will clarify if I wasn't clear enough
I pass the folder path as a renamed variable to a Persists Upload page (Because of the file size limitations in IIS 6.0 I found I can't use Binary. The only problem is I can't get the file to upload using the variable path I captured by using Upload.Save or Upload.SaveVirtual.
When I pass the path the first time I can view the variable but when I try to send it the second time through a hidden value using a second form, it won't pass. I know that I am getting the value to the second form successfully(I checked). I am using a Hidden Input Value to hold it.
I checked to see if the hidden value was retaining the variable correctly and it is. It just won't pass from the second form to the FORM ACTION page. I have the code below. I hope I included all of the relevant parts. Also, I am able to upload using standard paths (C:\*)
--------------------------------------------------------
ReCap of Goal
User goes to folder | Clicks Upload | Page appears to select file to upload | User Chooses File & Clicks Upload | File Uploads
-------------------------------------------------------
1) I passed the value of my First Form to my second form page. I received it and then renamed the variable before sending it on to my Upload form.
<% Dim Strpass
StrPass = request.form("Direct")%>
2) I passed the value to my Hidden Input
<FORM METHOD="POST" ENCTYPE="multipart/form-data" ACTION="Upload.asp">
<INPUT TYPE=FILE SIZE=60 NAME="FILE1"><BR>
<INPUT TYPE=HIDDEN Value="<%=StrPass%>" Name="PATH">
<INPUT TYPE=SUBMIT VALUE="Upload!">
</FORM>
3) My upload.asp page either gets error 500 (No friendly error showing)or acts like it worked (or Uploaded) and the file is not uploaded.
(upload.asp code below)
<%Response.Buffer = False
Dim NewPath
NewPath = request.form("Path")
Set Upload = Server.CreateObject("Persits.Upload.1")
Count = Upload.SaveVirtual(NewPath)%>
<%= Count %> files were uploaded
Please let me know if I need to list more code. I tried to put the main parts for what I am trying to accomplish. Any help is greatly appreciated. I will clarify if I wasn't clear enough