Why use a pop-up? When the form's submitted and validated, just output the
preview page, passing all values through with CF.

Gyrus
[EMAIL PROTECTED]
work: http://www.tengai.co.uk
play: http://www.norlonto.net
PGP key available

----- Original Message -----
From: "Russ" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Sunday, December 15, 2002 7:59 AM
Subject: Mildly OT: JS, Form, Passing Vars


> I am attempting to take values from a form that I have (it's a form that
> chooses recipient, sender, letter to be sent, custom header, custom
> footer and whether or not a password is sent to the user, for what it's
> worth) and then pass them to a pop-up window for display/preview prior
> to submitting and having all values combined into the email and sent,
> and then added to the database.
>
> I've found a couple of Javascript methods for handling this, but I'd
> prefer to keep the pop-up page reading the CF values--which it's not;
> it's saying that my FORM.values are undefined.
>
> Ideally, I'd simply like to pass all my values to the popup, display
> them, have a window.close and then allow the user to submit the letter,
> if they so choose, but right now, I'm not correctly passing anything.
>
> Here's what I'm working with (and it's probably butchered after a few
> tries here, so please bear with me):
>
> (button):  <input name="Submit2" type="Button" class="ButtonInv"
> onClick="newWin()" value="Preview Letter">
>
> <SCRIPT language="javascript" type="text/javascript">
> <!--
>
> <!--- Form name = Letter; trying to see if I can manipulate the code
> below to work for me; failing horribly --->
> <!--- document.Letter.action="letterPreview"; --->
> <!--- document.Letter.submit() --->
>
> function newWin(){
> var confirmWin =
> window.open('letterPreview.cfm','','width=800,height=600,scrollbars=yes,
> left=380,top=0')
>
>
> if(confirmWin.opener==null){
> confirmWin.opener = self;
> }
> }
>
> //-->
> </SCRIPT>
>
> And now, my head's starting to spin and I'm getting a little lost.
>
> Any assistance?
>
> Thanks very much!
>
> Russ
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm

Reply via email to