1. #1
    Sencha User
    Join Date
    Jan 2012
    Location
    Shanghai, China
    Posts
    21
    Answers
    1
    Vote Rating
    1
    tianhao is on a distinguished road

      0  

    Default Unanswered: how is the output format of php response to ajax request of grid

    Unanswered: how is the output format of php response to ajax request of grid


    hi
    here is grid which data store is ajax. when i use static text file, it works fine. here is the code of url definition:
    url: mytext.txt
    and the content is:
    {
    "items": [
    {
    "duty_id": 1,
    "ptype": "MEETING",
    "begin_date":'2012-04-05',
    "end_date":'2012-04-06',
    "pdesc":"desc1"
    },
    {
    "duty_id": 2,
    "ptype": "VOCATION",
    "begin_date":'2010-04-05',
    "end_date":'2010-04-06',
    "pdesc":"desc2"
    },
    {
    "duty_id": 3,
    "ptype": "MEETING",
    "begin_date":'2011-04-05',
    "end_date":'2011-04-06',
    "pdesc":"desc3"
    },
    ]
    }
    but when i use php to generate the same text, the web page is always loading.
    what is the output format of php response ?

  2. #2
    Sencha User
    Join Date
    Jan 2012
    Location
    Shanghai, China
    Posts
    21
    Answers
    1
    Vote Rating
    1
    tianhao is on a distinguished road

      0  

    Default


    sorry i made a mistake. response data must include column name like this:
    "duty_id": 3 not only 3.

  3. #3
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,918
    Answers
    655
    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


    include success: true in your result json

    Code:
    $return = array(
        'success' => TRUE,
        'data' => $data
    );
    
    $return = json_encode($return);
    Scott.

Thread Participants: 1

Tags for this Thread

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