Can't retrieve form values when specifying encoding type

N

Noozer

Hi!

I'm trying to use an ASP based upload object on a webpage. If I specify an
encoding type I cannot retrieve other values on the form. If I remove '
encType="multipart/form-data" ' then the values work as expected, but the
upload object fails. The javascript at the bottom of this message is the
code that submits the form, but the result is the same if I click the submit
button myself. Removing the "display:none;" styling doesn't change the
behavior either.

The ASP code that I am using to upload is located here:
http://www.asp101.com/articles/jacob/scriptupload.asp

-- Code snippets -----

<% 'ASP to read the form values. Also tried request.form("Key"). Located
before <head>
Key = request("Key")
Name= request("Name")
%>

<!-- Within Body -->
<form name="actionForm" id="actionForm" method="POST" action="subEdit.asp"
style="display: none;" encType="multipart/form-data">
<input type="text" name="Key" id="Key" value="">
<input type="text" name="Name" id="Name" value="">
<input type="file" name="file1" id="file1">
<input type="submit" name="submit" id="submit" value="submit">
</form>

//Load page with selected agent
function getAgent(key) {
document.forms("actionForm").reset();
document.forms("actionForm").Key.value = key;
document.forms("actionForm").submit();
}

How can I retrieve these values AND allow the upload object to function?
 
N

Noozer

I've found a different ASP uploader that works fine... Switching my code
over now... Thx anyhow!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,571
Members
45,045
Latest member
DRCM

Latest Threads

Top