dcsimg


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: Moving Data from Server to Client

  1. #1
    Mark Taylor Guest

    Moving Data from Server to Client


    Hi,
    I'm creating a page that has several list boxes, let's call these A1, A2,
    A3...A9. Depending on what is selected in A1, a list of items appears in
    list box B1, A2 corresponds to B2 etc. I'll refer to the B list boxes as
    Bx from here forward I don't want to have to go back to the server to retrieve
    the item list for each Bx list box everytime a selection is made in it's
    corresponding Ax list box because there are nine different A list boxes that
    the user will select from when they use the page, that would get frustrating.
    Here's a simple example using one of the nine list boxes, well call it Musical
    Preferences:

    ListBox A (Musical Preferences):
    Jazz
    Country
    Alternative
    HipHop

    If I select Jazz in list box A I want ListBox B to display:

    List Box B (Artists)
    Miles Davis
    John Coltrane
    Charles Mingus
    Thelonius Monk
    Duke Ellington
    etc

    If I select Alternative in List Box A I want ListBox B to display:

    List Box B (artists)
    The Cure
    Simple Minds
    Depeche Mode
    The Smiths
    etc

    Get the idea?

    The only way I can think of to handle this is to set up some hidden text
    areas so that the "lists" that will be placed in a B list box can be retrieved
    via javascript when the user selects an item in an A list box. In the old
    school, we would call this a kludge solution. Is there a better way?

    Many Thanks

    Mark


  2. #2
    Sarosh Sepai Guest

    Re: Moving Data from Server to Client


    You can use WDDX to send the data as WDDX packets to the client side and populate
    the list box (using Javascript) depending on the selection in A1.


    "Mark Taylor" <mtaylor1@cbsinc.com> wrote:
    >
    >Hi,
    >I'm creating a page that has several list boxes, let's call these A1, A2,
    >A3...A9. Depending on what is selected in A1, a list of items appears in
    >list box B1, A2 corresponds to B2 etc. I'll refer to the B list boxes as
    >Bx from here forward I don't want to have to go back to the server to retrieve
    >the item list for each Bx list box everytime a selection is made in it's
    >corresponding Ax list box because there are nine different A list boxes

    that
    >the user will select from when they use the page, that would get frustrating.
    > Here's a simple example using one of the nine list boxes, well call it

    Musical
    >Preferences:
    >
    >ListBox A (Musical Preferences):
    >Jazz
    >Country
    >Alternative
    >HipHop
    >
    >If I select Jazz in list box A I want ListBox B to display:
    >
    >List Box B (Artists)
    >Miles Davis
    >John Coltrane
    >Charles Mingus
    >Thelonius Monk
    >Duke Ellington
    >etc
    >
    >If I select Alternative in List Box A I want ListBox B to display:
    >
    >List Box B (artists)
    >The Cure
    >Simple Minds
    >Depeche Mode
    >The Smiths
    >etc
    >
    >Get the idea?
    >
    >The only way I can think of to handle this is to set up some hidden text
    >areas so that the "lists" that will be placed in a B list box can be retrieved
    >via javascript when the user selects an item in an A list box. In the old
    >school, we would call this a kludge solution. Is there a better way?
    >
    >Many Thanks
    >
    >Mark
    >



  3. #3
    Colo Guest

    Re: Moving Data from Server to Client


    What is WDDX?
    How to use WDDX?
    Can you give a sample?
    Many Thanks.



    "Sarosh Sepai" <sarosh@hotmail.com> wrote:
    >
    >You can use WDDX to send the data as WDDX packets to the client side and

    populate
    >the list box (using Javascript) depending on the selection in A1.
    >
    >
    >"Mark Taylor" <mtaylor1@cbsinc.com> wrote:
    >>
    >>Hi,
    >>I'm creating a page that has several list boxes, let's call these A1, A2,
    >>A3...A9. Depending on what is selected in A1, a list of items appears

    in
    >>list box B1, A2 corresponds to B2 etc. I'll refer to the B list boxes as
    >>Bx from here forward I don't want to have to go back to the server to retrieve
    >>the item list for each Bx list box everytime a selection is made in it's
    >>corresponding Ax list box because there are nine different A list boxes

    >that
    >>the user will select from when they use the page, that would get frustrating.
    >> Here's a simple example using one of the nine list boxes, well call it

    >Musical
    >>Preferences:
    >>
    >>ListBox A (Musical Preferences):
    >>Jazz
    >>Country
    >>Alternative
    >>HipHop
    >>
    >>If I select Jazz in list box A I want ListBox B to display:
    >>
    >>List Box B (Artists)
    >>Miles Davis
    >>John Coltrane
    >>Charles Mingus
    >>Thelonius Monk
    >>Duke Ellington
    >>etc
    >>
    >>If I select Alternative in List Box A I want ListBox B to display:
    >>
    >>List Box B (artists)
    >>The Cure
    >>Simple Minds
    >>Depeche Mode
    >>The Smiths
    >>etc
    >>
    >>Get the idea?
    >>
    >>The only way I can think of to handle this is to set up some hidden text
    >>areas so that the "lists" that will be placed in a B list box can be retrieved
    >>via javascript when the user selects an item in an A list box. In the

    old
    >>school, we would call this a kludge solution. Is there a better way?
    >>
    >>Many Thanks
    >>
    >>Mark
    >>

    >



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center