【问题标题】:Handsontable saving only 250 rowsHandsontable 仅保存 250 行
【发布时间】:2013-10-31 14:57:18
【问题描述】:

我在我的应用程序中使用handsontable。当我尝试使用 AJAX 和 PHP 保存数据时,我只能获得 250 行数据。是否有任何特定的配置,我需要更改才能保存handsontable 中的所有数据?我最近更改了我的css,这有影响吗? 请看下面的代码。

    $("#divButtons").find(".btnSubmit").click(function () {
   $.ajax({
    url: "saveData3.php",
    data: { "data" : $container.data('handsontable').getData()},
     //returns all cells' data
    dataType: 'json',
    type: 'POST',               
    success: function(){......})};

我的 php

  $post_data = $_POST['data'];
 if (!empty($post_data)) {
  $file = fopen('data_save3.json', 'w+');
  fwrite($file, json_encode($post_data));
  fclose($file);
//echo json_encode('success');
  } 

提前致谢

【问题讨论】:

  • CSS 很可能发挥作用。看看你是否有任何高度限制。
  • 你用过什么版本的 Handsontable?
  • 我尝试删除所有样式,但仍然只保存 250 行
  • 如果还有其他可能性,请告诉我。谢谢

标签: php jquery handsontable


【解决方案1】:

我终于让它工作了!我正在使用“下一步”按钮来保存可操作的数据并导航到下一页。现在,我分别使用了“保存”和“下一步”按钮。这样就解决了问题。

【讨论】:

    猜你喜欢
    • 2015-11-11
    • 2013-11-29
    • 2015-07-14
    • 2018-05-04
    • 2016-02-24
    • 2015-07-25
    • 2013-08-11
    • 2013-04-24
    • 2016-02-08
    相关资源
    最近更新 更多