• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 206
  • Last Modified:

.asp pages not processing

I am trying to create a multi-page form.  

I made the first page with a number of fields.  The form action is set to point to page2.asp.  I understand that page2 must have an asp extension for this to work.  

I made the page2.asp capture the data from the first page using a line like this for each field on the first page:
    <input name="comments" type="hidden" id="contact" size="50" value="<%=Request.Form("comments")%>">

I would like page2.asp to capture some more data in fields as well as process a file upload.  The goal is to get data from both forms emailed to an address and to have a file uploaded at the same time.  

When I test it out, the first page works: I am delivered to page2.asp as I would expect.   However, when I hit submit on page2.asp, the page just flashes and reappears.  No processing seems to happen, the file is not uploaded and the email is not sent.  If I rename the page to .htm and try it on its own, it does process fine.  

Somehow, changing the extension to .asp seems to be causing this.  Is there something else I need to do to make this work?  I am completely new to .asp files, so please do not assume that I know anything :)

Thanks!
0
boydicus
Asked:
boydicus
  • 2
  • 2
  • 2
2 Solutions
 
coreybryantCommented:
Are you using FP forms to process this?  If so, FP forms will not use the email bot.  You will need to use CDOSYS, JMail, ASPMail, ASPEmail etc

-Corey
0
 
AZwebCommented:
Just to clarify what Corey is trying to say...

The FrontPage forms results bots used to make the forms pages work will only work on HTML pages. If you try and use them on ASP pages they will not work. Microsoft did this on purpose to close up possible security points.

To do what you want to do you will need to make your own code and use a different email sender such as CDOSYS, JMail, ASPMail etc.

Here is a link to MS that shows how to send a form to two email addresses by piggy-backing two forms and you may be able to tweak the idea to fit your needs. http://support.microsoft.com/?scid=kb;en-us;825454&spid=2514&sid=229

I've used a similar way to send form data to a database and then to an email address before.

Good Luck...
0
 
boydicusAuthor Commented:
AZweb, thank you for your detailed response.  I took a look at the MS article you refer to.  This is good to know about, but it isn't what I am trying to do.  The server processes both forms in series, so this won't work for me.  What I need is to have the second form be presented to the user as well.

Perhaps I should back up a bit.  What I want to do is to collect several text fields and have those sent to an email address.  I also want to provide for a file to be uploaded.  I was planning to do this with one form to collect the data, then a second to process the upload, although if there is a way to do this on a sinlge form that would be fine.

And now that I think about it, if there were a way to attach the file to the email that is sent, that would actually be most prefered of all.  

Can you tell me what the best way would be to go about doing this?

Thank you!
  -Boyd
0
Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

 
coreybryantCommented:
You need to use CDOSYS, JMail, ASPMail, ASPEmail and then SAUpload, ASPupload, etc.  It depends on what your server supports.  FP cannot process forms via ASP unless you are dumping the information into database

-Corey
0
 
AZwebCommented:
FrontPage has a file upload feature added since the XP version if I remember right but it requires a file folder location to work.
Go to help in FrontPage and type in file upload and you should see the information on adding it to a form.

To send the file by email would require a custom form but you are also going to run into major problems with anti-virus programs killing files that may not be bad.

I use the file upload for an employment agency site I build and support and it works fine. Users can upload their resume this way to a folder. The company them gets user info and the resume file name info by email and can retrieve the file when needed.

We ensure the server virus protection and security is always current and files are tested before use as a second precaution.

You can still design your form in two parts if needed but I would use one form if at all possible to make it easier to work with.

I can't remember if I have built something like you are doing. If I get a chance I can look at some old projects to see if I have an example for you.

Good Luck...
0
 
boydicusAuthor Commented:
I want to thank you guys both for your help on this.  I can see there is a heck of a lot to learn here.

I was able to fix this by taking a step back and looking at what I was trying to do.  I was making it a lot harder than it needed to be.  All I needed to do was make a single page form using the upload component, and then add a bunch of text fields into that form.  Now the upload happens and I get my email.  Perfect!

Thank you.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now