How to formulate a file upload mime type for an ASPX page?
-
I am not sure whether or not this is in the right forum. Feel free to move it if it is not. I am having an issue formulating a form based file upload in HTML to an ASPX page on an IIS server. I am referencing RFC 1867 to get the appropriate syntax, and I guess RFC 1521 that outlines the MIME data streams. Here is the issue, the post itself is being formulated and works fine as long I do not add the filename="" parameter to the end of the content-disposition header. The second that filename="" parameter gets added to the content-disposition header for that particular parameter the ASPX page no longer recognizes it in the parameters collection. Is there something that I am doing wrong here? Here is a sample of the syntax being sent. WORKS: Content-Disposition: form-data; name="" DOES NOT WORK: Content-Disposition: form-data; name=""; filename="" Also, once this gets working I just have a couple other questions... #1) What should be the "proper" Content-Type parameter value for an XML file? Content-Type: text/XML? #2) If I send the Content-Transfer-Encoding: base64 parameter, will the ASPX page barf? #3) I am assuming that I can get the extended field parameter attributes somehow through ASPX, is this so? Please help...
~LizardWiz()
-
I am not sure whether or not this is in the right forum. Feel free to move it if it is not. I am having an issue formulating a form based file upload in HTML to an ASPX page on an IIS server. I am referencing RFC 1867 to get the appropriate syntax, and I guess RFC 1521 that outlines the MIME data streams. Here is the issue, the post itself is being formulated and works fine as long I do not add the filename="" parameter to the end of the content-disposition header. The second that filename="" parameter gets added to the content-disposition header for that particular parameter the ASPX page no longer recognizes it in the parameters collection. Is there something that I am doing wrong here? Here is a sample of the syntax being sent. WORKS: Content-Disposition: form-data; name="" DOES NOT WORK: Content-Disposition: form-data; name=""; filename="" Also, once this gets working I just have a couple other questions... #1) What should be the "proper" Content-Type parameter value for an XML file? Content-Type: text/XML? #2) If I send the Content-Transfer-Encoding: base64 parameter, will the ASPX page barf? #3) I am assuming that I can get the extended field parameter attributes somehow through ASPX, is this so? Please help...
~LizardWiz()
-
LizardWiz wrote:
I am having an issue formulating a form based file upload
Presumably you mean download?
Paul Marfleet
-
No I mean upload. Isn't there something in HTML that looks like this < INPUT type = "file" >?
~LizardWiz()
LizardWiz wrote:
Isn't there something in HTML that looks like this < INPUT type = "file" >?
That is HTML. If you are using ASP.NET 2.0, you can use the FileUpload[^]control to add file upload capabilities to your web page. .NET takes care of the low-level details for you.
Paul Marfleet
-
LizardWiz wrote:
Isn't there something in HTML that looks like this < INPUT type = "file" >?
That is HTML. If you are using ASP.NET 2.0, you can use the FileUpload[^]control to add file upload capabilities to your web page. .NET takes care of the low-level details for you.
Paul Marfleet
I am not formulating this post using an HTML page. I am formulating it in C++ from a windows service. When I use the syntax provided to me in RFC 1867,the ASPX page does not add the parameter into the form parameters collection. So my question is, how do I get the ASPX page to add the parameter into the forms parameter collection? And how can I access the extended parameter attributes?
~LizardWiz()