Multiple use of a form before it is submitted

Posted by OregonTrail on Stack Overflow See other posts from Stack Overflow or by OregonTrail
Published on 2012-04-15T17:13:02Z Indexed on 2012/04/15 17:29 UTC
Read the original article Hit count: 230

Filed under:
|
|
|

I'm new to JavaScript, and trying to figure out the canonical way to do the following.

I have a form with some checkboxes and a selector. Let's say the checkboxes are styles of music and the selector is for people's names.

I'd like the user to be able to select the styles of music for each of the people's names and then submit the form with all of the data.

For example, the user might first check off Classical, Jazz, Rock, and Pop and choose "Joe", then select Jazz, Pop, Country, and Electronica and choose "Jane". So there would have to be two different buttons for "submit person" and "submit form".

I would like to:

  1. Have a list of the names and their chosen styles populate below the form, for feedback
  2. Allow the user to use the form as much as they want, and then submit all the data at the end

I get the feeling that using jquery and JSON is perfect for this, but I'm not sure what search terminology to use to figure out how to do this.

If it matters, the form will be processed by a Django view in Python.

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about html