navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

Microsoft MVP

 

form based on previous selections

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> Expression Web Help >> form based on previous selections
Page: [1]
 
shoky

 

Posts: 25
Joined: 9/13/2005
Status: offline

 
form based on previous selections - 11/9/2007 19:46:53   
I need to build a form running multiple pages. The First field/page is selecting from a radio button list. One of these selections (contractor) should open a different form from all the other selections. Also on the Second page another field will have selections that will add additional fields to the Third page - and the Third page will send all data from the three pages by email

Any ideas on the best way to do it? The end result will be sent by mail only - so I'm trying to figure out a way to do it with out a database.
BobbyDouglas

 

Posts: 5455
Joined: 5/15/2003
From: Arizona
Status: offline

 
RE: form based on previous selections - 11/9/2007 21:06:34   
The way I would tackle this, is create the 3 pages first.

The first page will have a form that posts to the second page, then the second page will have a form that posts the first page's info, and the second page's info to the 3rd page. The 3rd page will make sure that there are posted values from the 1st and 2nd pages (to make sure spammers aren't using the form, and that the 3rd page was accessed by the 1st and 2nd page).

Here's an ASP tutorial explaining the method behind this: ASP Forms


_____________________________

Arizona Web Design - Mr Bobs Web Design in Arizona
The Arizona Web Hosting Challenge

(in reply to shoky)
shoky

 

Posts: 25
Joined: 9/13/2005
Status: offline

 
RE: form based on previous selections - 11/9/2007 21:23:30   
What I need the help with is some code like this on the second page: <% If Request.Form("Customer_Type") = "Contractor" Then %>
'THEN' would display one form and then have an ELSE IF to display the other form - same kind of thing needed on the third page - can it be done?

Don't have a lot of experience with .aspx but I want to build it in Expression.
*****************************************************************
OK here's the basic code I came up with, and it works:

<% Dim cstype=request.querystring("Customer_Type")
If cstype="Contractor" then%>
Hi.</p>
<p class="style5">You must be the Contractor. Please complete the form
<form method="post" action="" class="style5">
<input type="hidden" name="Customer_Type" value='<%=Request.querystring(" Customer_Type" )%>" ' />
<input name="Customer_Type" type="text" value='<%=Request.querystring("Customer_Type")%>' /></form>
<p class="style5"> </p>

<%else%>
<p class="style5">Hi!<p class="style5">Please complete the form
form method="post" action="" class="style5">
<input type="hidden" name="Customer_Type" value='<%=Request.querystring(" Customer_Type" )%>" ' />
<input name="Customer_Type" type="text" value='<%=Request.querystring("Customer_Type")%>' /></form>
<p class="style5">
</p></p></p>
<%end if%>


< Message edited by shoky -- 11/10/2007 9:00:06 >

(in reply to shoky)
Page:   [1]

All Forums >> Web Development >> Expression Web Help >> form based on previous selections
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts