mercredi 1 avril 2015

store the input field value in json and store it in a string using javascript

I'm new to json...if anyone can help me. Here is json format. how can i store the input field value in json and store it in a string using javascript



{
"noofrooms": "4",
"guests": "[ {
"adultcount ":" 1 ",
"childcount ":"0 ",
'chidage':'[]'
},
{
"adultcount ":"1 ",
"childcount ":"1 ",
'chidage':'[ "6 "]'
},
{
"adultcount ":"1 ",
"childcount ":"2 ",
'chidage':'[ "6 ","8 "]'
},
{
"adultcount ":"1 ",
"childcount ":"2 ",
'chidage':'["6 ", "8 "]'
}]"
}

Aucun commentaire:

Enregistrer un commentaire