Welcome to the { mindfrost82.com } forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Go Back   { mindfrost82.com } > Gadget Corner > Tech Newsgroups > Software > Adobe Software > Dreamweaver

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-29-2008, 03:30 AM
Daniel
 
Posts: n/a
Need help with Form Validation using If conditions

I have a page that has 2 forms on it.. and based on a selection make on the
previous page, they see the correct form needed.

My problem is that one of the forms is doing nothing but displaying their
selections from the previous page and only option is to submit the form..
the other form requires name and email to be completed to be sent along with
the other data that is dsiplayed on the screen.

Since i have 2 forms on the page and each form is being displayed based on a
value passed from the previous page... how can i setup the validation to
fall under that same if condition?

I tried using the same if condition wrapped around the validation code, but
it still lets the form post without any data in the fields

Any suggestions? any sites available that may explain this?

Each form has its own name, i tried the standard form validation within
dreamweaver and also the WA Validation ToolKit and i cant seem to get this..
can this be done? If so maybe im wrapping the wrong things in the
conditions..
i did notice that with the WA validation, it acknowledges the different
forms and i can pick the proper fields, but still nothing.


thanks in advance


--
************************************************
ASP, SQL2005, DW8 VBScript, Access


Reply With Quote
  #2 (permalink)  
Old 07-29-2008, 12:44 PM
Murray *ACE*
 
Posts: n/a
Re: Need help with Form Validation using If conditions

Have two forms on the page. each one has its own SUBMIT button. Use the
value passed from the previous page to determine which <form> tag gets -

style="display:none"

added inline.

Use the validation tool to validate each form's submission. It should work
like melted buttah.

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
==================


"Daniel" <dan_c@h.com> wrote in message
news:g6lvcl$fjd$1@forums.macromedia.com...
>I have a page that has 2 forms on it.. and based on a selection make on the
>previous page, they see the correct form needed.
>
> My problem is that one of the forms is doing nothing but displaying their
> selections from the previous page and only option is to submit the form..
> the other form requires name and email to be completed to be sent along
> with the other data that is dsiplayed on the screen.
>
> Since i have 2 forms on the page and each form is being displayed based on
> a value passed from the previous page... how can i setup the validation to
> fall under that same if condition?
>
> I tried using the same if condition wrapped around the validation code,
> but it still lets the form post without any data in the fields
>
> Any suggestions? any sites available that may explain this?
>
> Each form has its own name, i tried the standard form validation within
> dreamweaver and also the WA Validation ToolKit and i cant seem to get
> this.. can this be done? If so maybe im wrapping the wrong things in the
> conditions..
> i did notice that with the WA validation, it acknowledges the different
> forms and i can pick the proper fields, but still nothing.
>
>
> thanks in advance
>
>
> --
> ************************************************
> ASP, SQL2005, DW8 VBScript, Access
>


Reply With Quote
  #3 (permalink)  
Old 07-29-2008, 03:50 PM
Daniel
 
Posts: n/a
Re: Need help with Form Validation using If conditions

Thanks for the reply, but where should i apply that style?
here are my form tags and if conditions. ( no need to post all of the form )

<% If Request.Form("payment")= "P" Then %>
<form target="mypay" action=https://mypayment.com/ method="post"
name="payp" >

<% Else %>
<form action="email.asp" method="post" name="email" >


Should i be more specific with the If Request for the 2nd form like this?
<% If Request.Form("pay")= "P" Then %>
<form target="mypay" action=https://mypayment.com/ method="post"
name="payp" >
<% End If %>
<% If Request.Form("pay")= "E" Then %>
<form action="email.asp" method="post" name="email" >
<% End If %>


--
ASP, SQL2005, DW8 VBScript, Visual Studio 2005, Visual Studio 2008
"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:g6mvrt$j5i$1@forums.macromedia.com...
> Have two forms on the page. each one has its own SUBMIT button. Use the
> value passed from the previous page to determine which <form> tag gets -
>
> style="display:none"
>
> added inline.
>
> Use the validation tool to validate each form's submission. It should
> work like melted buttah.
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> ==================
>
>
> "Daniel" <dan_c@h.com> wrote in message
> news:g6lvcl$fjd$1@forums.macromedia.com...
>>I have a page that has 2 forms on it.. and based on a selection make on
>>the previous page, they see the correct form needed.
>>
>> My problem is that one of the forms is doing nothing but displaying their
>> selections from the previous page and only option is to submit the form..
>> the other form requires name and email to be completed to be sent along
>> with the other data that is dsiplayed on the screen.
>>
>> Since i have 2 forms on the page and each form is being displayed based
>> on a value passed from the previous page... how can i setup the
>> validation to fall under that same if condition?
>>
>> I tried using the same if condition wrapped around the validation code,
>> but it still lets the form post without any data in the fields
>>
>> Any suggestions? any sites available that may explain this?
>>
>> Each form has its own name, i tried the standard form validation within
>> dreamweaver and also the WA Validation ToolKit and i cant seem to get
>> this.. can this be done? If so maybe im wrapping the wrong things in the
>> conditions..
>> i did notice that with the WA validation, it acknowledges the different
>> forms and i can pick the proper fields, but still nothing.
>>
>>
>> thanks in advance
>>
>>
>> --
>> ************************************************
>> ASP, SQL2005, DW8 VBScript, Access
>>

>



Reply With Quote
  #4 (permalink)  
Old 07-29-2008, 04:03 PM
Murray *ACE*
 
Posts: n/a
Re: Need help with Form Validation using If conditions

So let me understand - the ELEMENTS within the form are the same? The only
difference between the two forms is the form tag itself? If that's the
case, I think you should take a different approach.

The page would have a single form on it. Use your logic to rewrite the
action attribute, e.g.,

<form <% if Request.Form("payment")= "P" then response.write('target="mypay"
action=https://mypayment.com/') else response.write(' action="email.asp"')
%> method="post" name="paypEmail" >


--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
==================


"Daniel" <dan_c@h.com> wrote in message
news:g6naoe$14h$1@forums.macromedia.com...
> Thanks for the reply, but where should i apply that style?
> here are my form tags and if conditions. ( no need to post all of the
> form )
>
> <% If Request.Form("payment")= "P" Then %>
> <form target="mypay" action=https://mypayment.com/ method="post"
> name="payp" >
>
> <% Else %>
> <form action="email.asp" method="post" name="email" >
>
>
> Should i be more specific with the If Request for the 2nd form like this?
> <% If Request.Form("pay")= "P" Then %>
> <form target="mypay" action=https://mypayment.com/ method="post"
> name="payp" >
> <% End If %>
> <% If Request.Form("pay")= "E" Then %>
> <form action="email.asp" method="post" name="email" >
> <% End If %>
>
>
> --
> ASP, SQL2005, DW8 VBScript, Visual Studio 2005, Visual Studio 2008
> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
> news:g6mvrt$j5i$1@forums.macromedia.com...
>> Have two forms on the page. each one has its own SUBMIT button. Use the
>> value passed from the previous page to determine which <form> tag gets -
>>
>> style="display:none"
>>
>> added inline.
>>
>> Use the validation tool to validate each form's submission. It should
>> work like melted buttah.
>>
>> --
>> Murray --- ICQ 71997575
>> Adobe Community Expert
>> (If you *MUST* email me, don't LAUGH when you do so!)
>> ==================
>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>> ==================
>>
>>
>> "Daniel" <dan_c@h.com> wrote in message
>> news:g6lvcl$fjd$1@forums.macromedia.com...
>>>I have a page that has 2 forms on it.. and based on a selection make on
>>>the previous page, they see the correct form needed.
>>>
>>> My problem is that one of the forms is doing nothing but displaying
>>> their selections from the previous page and only option is to submit the
>>> form..
>>> the other form requires name and email to be completed to be sent along
>>> with the other data that is dsiplayed on the screen.
>>>
>>> Since i have 2 forms on the page and each form is being displayed based
>>> on a value passed from the previous page... how can i setup the
>>> validation to fall under that same if condition?
>>>
>>> I tried using the same if condition wrapped around the validation code,
>>> but it still lets the form post without any data in the fields
>>>
>>> Any suggestions? any sites available that may explain this?
>>>
>>> Each form has its own name, i tried the standard form validation within
>>> dreamweaver and also the WA Validation ToolKit and i cant seem to get
>>> this.. can this be done? If so maybe im wrapping the wrong things in the
>>> conditions..
>>> i did notice that with the WA validation, it acknowledges the different
>>> forms and i can pick the proper fields, but still nothing.
>>>
>>>
>>> thanks in advance
>>>
>>>
>>> --
>>> ************************************************
>>> ASP, SQL2005, DW8 VBScript, Access
>>>

>>

>
>


Reply With Quote
  #5 (permalink)  
Old 07-29-2008, 04:39 PM
Daniel
 
Posts: n/a
Re: Need help with Form Validation using If conditions

they have a few different elements.. because of the process each has to go
thru..

i guess i can make them both the same and pass the fields on need based on
the logic

--
ASP, SQL2005, DW8 VBScript, Visual Studio 2005, Visual Studio 2008
"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:g6nbgb$1rl$1@forums.macromedia.com...
> So let me understand - the ELEMENTS within the form are the same? The
> only difference between the two forms is the form tag itself? If that's
> the case, I think you should take a different approach.
>
> The page would have a single form on it. Use your logic to rewrite the
> action attribute, e.g.,
>
> <form <% if Request.Form("payment")= "P" then
> response.write('target="mypay" action=https://mypayment.com/') else
> response.write(' action="email.asp"') %> method="post" name="paypEmail" >
>
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> ==================
>
>
> "Daniel" <dan_c@h.com> wrote in message
> news:g6naoe$14h$1@forums.macromedia.com...
>> Thanks for the reply, but where should i apply that style?
>> here are my form tags and if conditions. ( no need to post all of the
>> form )
>>
>> <% If Request.Form("payment")= "P" Then %>
>> <form target="mypay" action=https://mypayment.com/ method="post"
>> name="payp" >
>>
>> <% Else %>
>> <form action="email.asp" method="post" name="email" >
>>
>>
>> Should i be more specific with the If Request for the 2nd form like this?
>> <% If Request.Form("pay")= "P" Then %>
>> <form target="mypay" action=https://mypayment.com/ method="post"
>> name="payp" >
>> <% End If %>
>> <% If Request.Form("pay")= "E" Then %>
>> <form action="email.asp" method="post" name="email" >
>> <% End If %>
>>
>>
>> --
>> ASP, SQL2005, DW8 VBScript, Visual Studio 2005, Visual Studio 2008
>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>> news:g6mvrt$j5i$1@forums.macromedia.com...
>>> Have two forms on the page. each one has its own SUBMIT button. Use
>>> the value passed from the previous page to determine which <form> tag
>>> gets -
>>>
>>> style="display:none"
>>>
>>> added inline.
>>>
>>> Use the validation tool to validate each form's submission. It should
>>> work like melted buttah.
>>>
>>> --
>>> Murray --- ICQ 71997575
>>> Adobe Community Expert
>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>> ==================
>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>> ==================
>>>
>>>
>>> "Daniel" <dan_c@h.com> wrote in message
>>> news:g6lvcl$fjd$1@forums.macromedia.com...
>>>>I have a page that has 2 forms on it.. and based on a selection make on
>>>>the previous page, they see the correct form needed.
>>>>
>>>> My problem is that one of the forms is doing nothing but displaying
>>>> their selections from the previous page and only option is to submit
>>>> the form..
>>>> the other form requires name and email to be completed to be sent along
>>>> with the other data that is dsiplayed on the screen.
>>>>
>>>> Since i have 2 forms on the page and each form is being displayed based
>>>> on a value passed from the previous page... how can i setup the
>>>> validation to fall under that same if condition?
>>>>
>>>> I tried using the same if condition wrapped around the validation code,
>>>> but it still lets the form post without any data in the fields
>>>>
>>>> Any suggestions? any sites available that may explain this?
>>>>
>>>> Each form has its own name, i tried the standard form validation within
>>>> dreamweaver and also the WA Validation ToolKit and i cant seem to get
>>>> this.. can this be done? If so maybe im wrapping the wrong things in
>>>> the conditions..
>>>> i did notice that with the WA validation, it acknowledges the different
>>>> forms and i can pick the proper fields, but still nothing.
>>>>
>>>>
>>>> thanks in advance
>>>>
>>>>
>>>> --
>>>> ************************************************
>>>> ASP, SQL2005, DW8 VBScript, Access
>>>>
>>>

>>
>>

>



Reply With Quote
  #6 (permalink)  
Old 07-29-2008, 04:59 PM
Murray *ACE*
 
Posts: n/a
Re: Need help with Form Validation using If conditions

That could work.

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
==================


"Daniel" <dan_c@h.com> wrote in message
news:g6ndjk$4ei$1@forums.macromedia.com...
> they have a few different elements.. because of the process each has to go
> thru..
>
> i guess i can make them both the same and pass the fields on need based on
> the logic
>
> --
> ASP, SQL2005, DW8 VBScript, Visual Studio 2005, Visual Studio 2008
> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
> news:g6nbgb$1rl$1@forums.macromedia.com...
>> So let me understand - the ELEMENTS within the form are the same? The
>> only difference between the two forms is the form tag itself? If that's
>> the case, I think you should take a different approach.
>>
>> The page would have a single form on it. Use your logic to rewrite the
>> action attribute, e.g.,
>>
>> <form <% if Request.Form("payment")= "P" then
>> response.write('target="mypay" action=https://mypayment.com/') else
>> response.write(' action="email.asp"') %> method="post" name="paypEmail"
>> >

>>
>>
>> --
>> Murray --- ICQ 71997575
>> Adobe Community Expert
>> (If you *MUST* email me, don't LAUGH when you do so!)
>> ==================
>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>> ==================
>>
>>
>> "Daniel" <dan_c@h.com> wrote in message
>> news:g6naoe$14h$1@forums.macromedia.com...
>>> Thanks for the reply, but where should i apply that style?
>>> here are my form tags and if conditions. ( no need to post all of the
>>> form )
>>>
>>> <% If Request.Form("payment")= "P" Then %>
>>> <form target="mypay" action=https://mypayment.com/ method="post"
>>> name="payp" >
>>>
>>> <% Else %>
>>> <form action="email.asp" method="post" name="email" >
>>>
>>>
>>> Should i be more specific with the If Request for the 2nd form like
>>> this?
>>> <% If Request.Form("pay")= "P" Then %>
>>> <form target="mypay" action=https://mypayment.com/ method="post"
>>> name="payp" >
>>> <% End If %>
>>> <% If Request.Form("pay")= "E" Then %>
>>> <form action="email.asp" method="post" name="email" >
>>> <% End If %>
>>>
>>>
>>> --
>>> ASP, SQL2005, DW8 VBScript, Visual Studio 2005, Visual Studio 2008
>>> "Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
>>> news:g6mvrt$j5i$1@forums.macromedia.com...
>>>> Have two forms on the page. each one has its own SUBMIT button. Use
>>>> the value passed from the previous page to determine which <form> tag
>>>> gets -
>>>>
>>>> style="display:none"
>>>>
>>>> added inline.
>>>>
>>>> Use the validation tool to validate each form's submission. It should
>>>> work like melted buttah.
>>>>
>>>> --
>>>> Murray --- ICQ 71997575
>>>> Adobe Community Expert
>>>> (If you *MUST* email me, don't LAUGH when you do so!)
>>>> ==================
>>>> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
>>>> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
>>>> ==================
>>>>
>>>>
>>>> "Daniel" <dan_c@h.com> wrote in message
>>>> news:g6lvcl$fjd$1@forums.macromedia.com...
>>>>>I have a page that has 2 forms on it.. and based on a selection make on
>>>>>the previous page, they see the correct form needed.
>>>>>
>>>>> My problem is that one of the forms is doing nothing but displaying
>>>>> their selections from the previous page and only option is to submit
>>>>> the form..
>>>>> the other form requires name and email to be completed to be sent
>>>>> along with the other data that is dsiplayed on the screen.
>>>>>
>>>>> Since i have 2 forms on the page and each form is being displayed
>>>>> based on a value passed from the previous page... how can i setup the
>>>>> validation to fall under that same if condition?
>>>>>
>>>>> I tried using the same if condition wrapped around the validation
>>>>> code, but it still lets the form post without any data in the fields
>>>>>
>>>>> Any suggestions? any sites available that may explain this?
>>>>>
>>>>> Each form has its own name, i tried the standard form validation
>>>>> within dreamweaver and also the WA Validation ToolKit and i cant seem
>>>>> to get this.. can this be done? If so maybe im wrapping the wrong
>>>>> things in the conditions..
>>>>> i did notice that with the WA validation, it acknowledges the
>>>>> different forms and i can pick the proper fields, but still nothing.
>>>>>
>>>>>
>>>>> thanks in advance
>>>>>
>>>>>
>>>>> --
>>>>> ************************************************
>>>>> ASP, SQL2005, DW8 VBScript, Access
>>>>>
>>>>
>>>
>>>

>>

>
>


Reply With Quote
Reply

  { mindfrost82.com } > Gadget Corner > Tech Newsgroups > Software > Adobe Software > Dreamweaver


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 06:23 AM.


Powered by vBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
© 1999-2008 mindfrost82.com v11.0


Sponsors:
Debt Help | Mortgage Calculator | Credit Card | Shares | Credit Cards



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114