1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => [htmlstate] => on_nl2br [postusername] => ScottyMTL [ip] => pscantland@yaho [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 4 [islastshown] => [isfirstshown] => [attachments] => [allattachments] => ) --> A 'Global' Variable passing through Forms - Coldfusion - Advanced Techniques

A 'Global' Variable passing through Forms - Coldfusion - Advanced Techniques

Hi, As an example, I have 3 pages of booking forms, Book1.cfm, Book2.cfm, and Book3.cfm Data is entered in Book1.cfm and Posted to Book2.cfm. in Book2.cfm, other data is then selected, and posted to Book3. In Book3.cfm I can easily use the data selected in Book2.cfm, by using the Form. Function. What command can i use in Book3 to use the Data selected in Book1 (that was posted to Book2) In your explination can you make sure you refer to the Book Names! ************************************************** ************** Alternitavly (only using 2 Booking Forms), I could have 2 Data entry's on Book1.cfm, which ...

Sponsored Links
  1. #1

    Default A 'Global' Variable passing through Forms

    Hi,

    As an example, I have 3 pages of booking forms, Book1.cfm, Book2.cfm, and
    Book3.cfm

    Data is entered in Book1.cfm and Posted to Book2.cfm. in Book2.cfm, other data
    is then selected, and posted to Book3.

    In Book3.cfm I can easily use the data selected in Book2.cfm, by using the
    Form. Function.

    What command can i use in Book3 to use the Data selected in Book1 (that was
    posted to Book2)

    In your explination can you make sure you refer to the Book Names!

    ************************************************** **************
    Alternitavly (only using 2 Booking Forms), I could have 2 Data entry's on
    Book1.cfm, which then passes to the final booking form Book2.cfm Is it possible
    to have different data (typed in a text box, and selected from a cfselect)
    passed over using only the ONE Submit Button????
    ************************************************** **************

    Thank you in advance for you help!

    Sponsored Links
    bluebirds1984 Guest

  2. #2

    Default Re: A 'Global' Variable passing through Forms

    In book2.cfm, set session variables.

    Originally posted by: bluebirds1984
    Hi,

    As an example, I have 3 pages of booking forms, Book1.cfm, Book2.cfm, and
    Book3.cfm

    Data is entered in Book1.cfm and Posted to Book2.cfm. in Book2.cfm, other data
    is then selected, and posted to Book3.

    In Book3.cfm I can easily use the data selected in Book2.cfm, by using the
    Form. Function.

    What command can i use in Book3 to use the Data selected in Book1 (that was
    posted to Book2)

    In your explination can you make sure you refer to the Book Names!

    ************************************************** **************
    Alternitavly (only using 2 Booking Forms), I could have 2 Data entry's on
    Book1.cfm, which then passes to the final booking form Book2.cfm Is it possible
    to have different data (typed in a text box, and selected from a cfselect)
    passed over using only the ONE Submit Button????
    ************************************************** **************

    Thank you in advance for you help!



    Dan Guest

  3. #3

    Default Re: A 'Global' Variable passing through Forms

    Two ways come to mind. Book 2 receives the form fields from Book1. Within
    your form on Book 2, place <INPUT TYPE="hidden" ... > for each Book 1 form
    field you want to pass to Book 3 (see code below). The other way is, in Book
    2, to assign the form fields from Book 1 to session variables. To do this,
    you will need to have an Application.cfm page and declare the use of session
    variables there.


    <!--- Book 1 --->
    <INPUT TYPE="text" NAME-"foo" ... >

    <!--- Book 2 --->
    <CFOUTPUT>
    <INPUT TYPE="hidden" NAME="foo" VALUE="#FORM.foo# ... >
    </CFOUTPUT>

    jdeline Guest

  4. #4

    Default Re: A 'Global' Variable passing through Forms

    jdeline posted a good way.

    I personnaly prefer to automatically convert anything in the form scope to the
    session scope... Basically on the final processing page I use the session
    variables instead of form variables. This is useful for, say, a checkout
    process where you want to store the data as the user advance in the process...
    so you "remember" his previous choices and use them in the form fields.

    input type="text" name="firstname" value="#session.firstname#"

    Do not forget to use cfparam name="session.firstname" default="" in the
    Application.cfm page or in the beginning of your page expecting that value.

    ScottyMTL Guest

  5. #5

    Default Re: A 'Global' Variable passing through Forms

    thank you for your help, I will try these suggestions in the next few days and get back to you.

    Cheers
    bluebirds1984 Guest

Similar Threads

  1. problem passing variable between forms.
    By Angelo Zanetti in forum PHP Development
    Replies: 4
    Last Post: April 10th, 06:02 PM
  2. passing global variable by reference?
    By Don S in forum PERL Modules
    Replies: 2
    Last Post: February 22nd, 02:56 PM
  3. passing Conf object from Global.asa to a dll
    By Aksahy in forum ASP Components
    Replies: 1
    Last Post: August 13th, 01:02 PM
  4. Replies: 0
    Last Post: July 17th, 09:23 AM
  5. Replies: 7
    Last Post: July 17th, 04:54 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •