Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder
    Join Date
    Jun 2012
    Thanked 0 Times in 0 Posts

    Lightbulb Populating secondary list from primary list

    I want to present my users with a list of 200 items.
    From that list, they pick 10 items.
    The item selected shows up in the secondary list.
    Which then creates their items into an array for a playlist.

    What's a good way of doing this?

  2. #2
    Senior Coder
    Join Date
    Sep 2010
    Thanked 275 Times in 275 Posts
    Two ways come to mind. First, a couple of hundred check boxes. But a better way might be using a drop down menu to choose an item, then an 'Add this Item' button to add it to the playlist. You could add the item to a javascript array, when the array count reached 10 a notice would be given, you could make the array the value of a hidden input and submit it in a form, then make the playlist with php.
    Welcome to http://www.myphotowizard.net

    where you can edit images, make a photo calendar, add text to images, and do much more.

    When you know what you're doing it's called Engineering, when you don't know, it's called Research and Development. And you can always charge more for Research and Development.

  3. #3
    Master Coder sunfighter's Avatar
    Join Date
    Jan 2011
    Thanked 1,013 Times in 1,010 Posts
    I like this method:
    Code is there. You can pick a random bunch of items and move em back and forth.
    I think you will need to code the 10 limit into it and assign items to an array, but this is a good start.

    But Suwannee_guy, anytime you are changing the HTML your looking at its done by javascript not php.
    Last edited by sunfighter; 10-23-2013 at 07:24 AM.
    Evolution - The non-random survival of random variants.
    Physics is actually atoms trying to understand themselves.


Posting Permissions

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