title: How to stay on particular page after perform delete in jquery serverside datatable?
body: <p>I am working with jquery server-side datatable. I want to stay on a particular page from where  I deleted the record. 
  For example: Suppose I have 30 records and page size of datatable is 10. I selected second page and delete the 15 no record, at this time i want to stay on this second no. page.</p>
  
  <p>But in my case every time when i performed delete it put me in first page. How to set the number of page after delete record from a particular page number?</p>
  
  <p>My code is as bellow:-</p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;div class="row"&gt;
  &lt;div class="col-md-12"&gt;
      &lt;table class="table-responsive" id="example"&gt;
          &lt;thead&gt;
              &lt;tr&gt;
                  &lt;th&gt;
                      Name
                  &lt;/th&gt;
                  &lt;th&gt;
                      Description
                  &lt;/th&gt;
                  &lt;th&gt;
                      Class
                  &lt;/th&gt;
                  &lt;th&gt;
                      Action
                  &lt;/th&gt;
              &lt;/tr&gt;
          &lt;/thead&gt;
          &lt;tbody&gt;&lt;/tbody&gt;
      &lt;/table&gt;
      &lt;input type="hidden" name="IsDeleteCall" id="IsDeleteCall" value="false" /&gt;
      &lt;input type="hidden" name="IdToDelete" id="IdToDelete" value=" " /&gt;
      &lt;input type="hidden" name="displayStartIndex" id="hdndisplayStartIndex" value=" " /&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p></p>
  
  <pre class="lang-js prettyprint-override"><code>&lt;script type="text/javascript"&gt;
      var table;
      $(document).ready(function () {
          table = $('#example').DataTable({
              "bJQueryUI": true,
              "bSortClasses": false,
              "bSortable": true,
              "aaSorting": [[0, 'desc']],
              "bAutoWidth": true,
              "bInfo": true,
              //"sScrollX": "100%",
              "bScrollCollapse": true,
              "sPaginationType": "full_numbers",
              "bRetrieve": true,
              "bServerSide": true,
              "sAjaxSource": "/Home/GetCustomers/",
              "iDisplayStart": 10,
              "fnServerData": function (sSource, aoData, fnCallback, oSettings) {
                  var colCount = aoData[1].value;
                  var sSearch = fnGetKey(aoData, "sSearch");
                  var sSort = fnGetKey(aoData, "iSortCol_0");
                  var sDir = fnGetKey(aoData, "sSortDir_0");
  
                  var jsonData = {
                      sSortDir: sDir,
                      sSort: sSort,
                      sSearch: sSearch,
                      sEcho: aoData[0].value,
                      iDisplayLength: aoData[4].value,
                      iDisplayStart: $('#hdndisplayStartIndex').val() == 0 ? aoData[3].value : $('#hdndisplayStartIndex').val(),
                      // iDisplayStart: aoData[3].value,
                      IsDeleteCall: $('#IsDeleteCall').val(),
                      IdToDelete: $('#IdToDelete').val()
                  }
  
                  $.ajax({
                      "dataType": 'json',
                      "type": "POST",
                      "url": sSource,
                      "data": jsonData,
                      "success": fnCallback
                  });
              },
              "fnInitComplete": function () {
              }
  
          });
  
  
  
  
      });
  
      function fnGetKey(aoData, sKey) {
          for (var i = 0, iLen = aoData.length; i &lt; iLen; i++) {
              if (aoData[i].name == sKey) {
                  return aoData[i].value;
              }
          }
          return null;
      }
  
      function deleteRow(e) {
  
          var id = $(e.target).attr('id');
          $('#IsDeleteCall').val(true);
          $('#IdToDelete').val(id);
          $(e.target).parent().parent().attr('userId', id);
          var displayStart = $(e.target).attr('displayStart');
          $('#hdndisplayStartIndex').val(displayStart);
          table.row($('tr[userid=' + id + ']')).remove().draw(true);
          $('#hdndisplayStartIndex').val(0);
          // table.row($(e.target).parent().parent()).remove().draw(false);
      }
  
  &lt;/script&gt;
  </code></pre>