title: Creating data using JTable
body: <p>Good day, i am using jtable to create data, it saves the data but it says 'An error occured while communicating to the server'. When i check the database it successfully inserts the data. There are 2 fields in jtable , a text area and a drop down. Here is my jtable code</p>
  
  <pre><code>&lt;script&gt;
  $(function () { 
    $('#div').jtable({
              title: 'Division',
              paging: true, //Enable paging
              pageSize: 15, //Set page size (default: 10)
              sorting: true, //Enable sorting
              actions: {
                  listAction: 'CRUD/Read.php',
                  createAction: 'CRUD/Create.php',
                  updateAction: 'CRUD/Edit.php',
                  deleteAction: 'CRUD/Delete.php'
              },
              fields: {
                  Id: {
                      key: true,
                      list: false
                  },
                  Description: {
                      title: 'Name',
                      width: '40%',
                      type: 'textarea'
                  },
                  IsActive: {
                      title: 'In Use',
                      width: '40%',
                      options: { 'N': 'No', 'Y': 'Yes' }
                  }
              }
          });
  
      $('#div').jtable('load');
  });
  &lt;/script&gt;
  </code></pre>
  
  <p>and here is the php code</p>
  
  <pre><code>&lt;?php
  //Insert record into database
  $des = $_POST['ArticleDescription'];
  $isActive = $_POST['IsActive'];
  if($isActive == 'N'){
  $query = mysql_query("INSERT INTO table VALUES( NULL,'" . $des . "','N')");
  }
  else
  {
  $updateAll = mysql_query("Update table Set IsActive = 'N'");    
  $query = mysql_query("INSERT INTO table VALUES( NULL,'" . $des. "','Y')");  
  }
  //Get last inserted record (to return to jTable)
  $result = mysql_query("SELECT * FROM table WHERE Id = LAST_INSERT_ID();");
  $row = mysql_fetch_array($result);
  //Return result to jTable
  $jTableResult = array();
  $jTableResult['Result'] = "OK";
  $jTableResult['Record'] = $result;
  print json_encode($jTableResult);
  ?&gt;
  </code></pre>