1. #1
    Sencha User
    Join Date
    Feb 2012
    Posts
    78
    Vote Rating
    0
    alfa19 is on a distinguished road

      0  

    Default Parsing data into JSON

    Parsing data into JSON


    Hi,

    i've a form containing 2 fieldset. Every fieldset have these fields:

    - author
    - title
    - date

    if i do this:

    PHP Code:
    Ext.JSON.encodeValue(form.getValues()), 
    the result is:

    {"author":["a1","a2"],"title":["t1","t2"],date:["d1","d2"]}

    while i want to submit a json like this

    [{"author":"a1","title":"t1","date":"d1"},{"author":"a2","title":"t2","date":"d2"}]

    how can i do?

    thanks a lot

  2. #2
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,927
    Vote Rating
    443
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    Provide a unique name (name: 'author1') to each field.

    Regards,
    Scott.

  3. #3
    Sencha User
    Join Date
    Feb 2012
    Posts
    78
    Vote Rating
    0
    alfa19 is on a distinguished road

      0  

    Default


    of course but than i don't have the inner detail.

    with your solution i have a json like this:

    [{"author1": ["a1","t1","d1"],"author2":["a2","t2","d2"]}

    and it is different from:

    [{"author":"a1","title":"t1","date":"d1"},{"author":"a2","title":"t2","date":"d2"}]

  4. #4
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,927
    Vote Rating
    443
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    Please show the code for your form.

    Scott.

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi