Results 1 to 7 of 7

Thread: Output variable?

  1. #1
    Join Date
    May 2006
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Output variable?

    DD: Chained selects
    http://www.dynamicdrive.com/dynamici...ects/index.htm

    I have implemented the above script on my page, but I'm interested in getting the data out as variables.
    Is this possible?
    I'm also interested in getting a variable, not visible to the user, is this possible?

    The point is to send the values to "the next page" for reviewing by the user.

    I hope this makes sense

    Best regards
    Danjel

  2. #2
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    The script uses form elements. You can submit the form to a server-side script just as with any other form.

    Is this what you meant?
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  3. #3
    Join Date
    May 2006
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Well, some of it.

    If we take the example from the web.
    The customer has found a car using the picklists.
    Then I want to show the selections the customer made on a new webpage, including the price of the car, and some extra options (Those have nothing to do with the DD script).

    So, what I'm looking for, is a way to get the price sent to the next page.
    The price is not shown in any of the picklists though.

    An alternate option would be to have the price shown on the first page with the picklists, so that it changes, depending on the selections made by the customer. I know that this is not in the DD script, but I need the price, anyway.

    I hope this made it easier to understand :-)

    TIA
    Danjel

  4. #4
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    No, you need the price to be stored server-side and retrieved according to the model selected.

    Or you'll get people ordering £10,000 cars and paying tuppence.
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  5. #5
    Join Date
    May 2006
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I know that it is possible to fake the price, but that is not critical for me at this point.

    But a way for me to get around it could be to hide a field, is that possible?

    I have tried "type=hidden", but that does not work, maybe because it is a "<select...".

    I have tried to change it to "<input ...", but then the field is just empty.

    Any new ideas ?

    I will, of course, send the resulting code to you, if you are interested.

    TIA
    Danjel

  6. #6
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    style="display:none;" will hide your select box.
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  7. #7
    Join Date
    May 2006
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Just what I needed :-)

    Thanks.

    DJ

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
  •