logo-dw

Go Back   Dreamweaver Club Forums > Dreamweaver forums > Dreamweaver General
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 02-10-2009, 01:43 PM   #1
urbanrays
 
Join Date: Dec 2008
Posts: 212
Default submit button on form

Hi All

Its very quiet on here today so I'll create a post.

I have a email form and the submit button has 2 actions first is to validate the form and the second is to pop up a thank you message "using pop up" in behaviours, the trouble is that if the form is not filled out completely the form will pop the message telling the user which fields are required and then instantly pops the thank you message up too.

What I need to happen is for the thank you message to pop up once the form has been fully validated.

If you need to have a look what I mean the site is www.urbanrays.co.uk/commercial.htm

Thanks for your help
urbanrays is offline   Reply With Quote
Old 02-10-2009, 02:18 PM   #2
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

That's just the HTML page. The form processing is in commercial.php.

You should just remove the javascript pop-up for thank you message.
Have commercial.php redirect to a separate thankyou page if the form was successfully sent.
domedia is offline   Reply With Quote
Old 02-10-2009, 03:01 PM   #3
urbanrays
 
Join Date: Dec 2008
Posts: 212
Default

This may sound like I am being a fussy a##e, but i wanted just a small pop up thank you message and redirect back to home page.
By the looks of things I have 2 options either have the form validation and loose the pop up or vice versa.
Thanks for your help
urbanrays is offline   Reply With Quote
Old 02-10-2009, 03:42 PM   #4
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

no you can still have the pop-up, but you have to call it after the form has been successfully sent.
domedia is offline   Reply With Quote
Old 02-10-2009, 04:15 PM   #5
urbanrays
 
Join Date: Dec 2008
Posts: 212
Default

Oooo didnt realise this, The problem I am having is that I dont touch php with a barge pole and the software I use just generates the php the only thing it requests is the email address, thankyou.htm and the error.htm, the code the software produces that is placed on the form is this

<input type="hidden" name="hdwemail" id="hdwemail" value="emailaddress" />
<input type="hidden" name="hdwok" id="hdwok" value="thanks.htm" />
<input type="hidden" name="hdwnook" id="hdwnook" value="error.htm" />

How do I create a pop up from here

Thanks for your help
urbanrays is offline   Reply With Quote
Old 02-10-2009, 06:56 PM   #6
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

No idea, you need to edit your PHP file. If it's a canned solution, you're stuck with it.
domedia is offline   Reply With Quote
Old 02-10-2009, 06:59 PM   #7
Ricky55
Ricky55's Avatar
 
Join Date: Oct 2005
Location: West Yorkshire, UK
Posts: 1,855
Default

just got your PM Urbanrays, are you all sorted now? I didn't quite get what you meant.

Does this work how you want if so I'll send you the script.

http://www.dentvanishltd.co.uk/contact.html
__________________
Qwerty Design

Check out my blog for web design insights.
http://www.qwerty-design.co.uk/
Follow me on Twitter: @QwertyDesignUK
Ricky55 is offline   Reply With Quote
Old 02-10-2009, 07:41 PM   #8
urbanrays
 
Join Date: Dec 2008
Posts: 212
Default

Hi yeah that works,
Thanks for that mate if you could post us the script for that I will try and get it to work in my tabbed pages,id prefer to tackle the CSS than take a crash course in zargonian and learn that alien language PHP

Thanks again mate
urbanrays is offline   Reply With Quote
Reply


Thread Tools
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:29 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com