新浪微博 登陆  注册   设为首页 加入收藏

学PHP >> 最新源码 >> ajax table edit 表格控制

ajax table edit 表格控制

查看次数7578 发表时间2010-06-16 23:29:41

程序名称:Ajax Table Edit
开发者/组织名称:Andrew Sullivan
运行环境:php+mysql,php+文本
官方网站:http://stroz.us/php/
下载地址:
请下载附件中的源码,不要直接复制 (已下载 965 次)

文章来源:http://www.OSphp.com.cn
程序介绍:
This class can be used to edit data in the cells of an HTML table using AJAX to save the changed cell values without reloading the current page. //OsPHP.COM.CN

It takes an bi-dimensional array as parameter to define the contents of the cells of the table to be edited. Then it generates the table HTML with the necessary JavaScript code to edit the cell contents.

The user may edit the cells by clicking on them. The cell is turned into a text input so the user can alter the cell contents with the keyboard. If you are using AdvATE then you can specify the type of input you want returned: text, textarea, select, radio, and checkboxes. For the latter three, you are able to specify the inputs and values to be presented to the user.

When the cell editing is finished, the data is saved using AJAX to send to the server the new cell value and the respective table row and column number.

引用
a:20:{i:0;a:4:{s:4:"row0";s:14:"Row 0 column 0";s:4:"row1";s:14:"Row 0 column 1";s:4:"row2";s:14:"Row 0 column 2";s:4:"row3";s:14:"Row 0 column 3";}i:1;a:4:{s:4:"row0";s:14:"Row 1 column 0";s:4:"row1";s:14:"Row 1 column 1";s:4:"row2";s:14:"Row 1 column 2";s:4:"row3";s:14:"Row 1 column 3";}i:2;a:4:{s:4:"row0";s:14:"Row 2 column 0";s:4:"row1";s:14:"Row 2 column 1";s:4:"row2";s:14:"Row 2 column 2";s:4:"row3";s:14:"Row 2 column 3";}i:3;a:4:{s:4:"row0";s:14:"Row 3 column 0";s:4:"row1";s:14:"Row 3 column 1";s:4:"row2";s:14:"Row 3 column 2";s:4:"row3";s:14:"Row 3 column 3";}i:4;a:4:{s:4:"row0";s:14:"Row 4 column 0";s:4:"row1";s:14:"Row 4 column 1";s:4:"row2";s:14:"Row 4 column 2";s:4:"row3";s:14:"Row 4 column 3";}i:5;a:4:{s:4:"row0";s:14:"Row 5 column 0";s:4:"row1";s:14:"Row 5 column 1";s:4:"row2";s:14:"Row 5 column 2";s:4:"row3";s:14:"Row 5 column 3";}i:6;a:4:{s:4:"row0";s:14:"Row 6 column 0";s:4:"row1";s:14:"Row 6 column 1";s:4:"row2";s:14:"Row 6 column 2";s:4:"row3";s:14:"Row 6 column 3";}i:7;a:4:{s:4:"row0";s:14:"Row 7 column 0";s:4:"row1";s:14:"Row 7 column 1";s:4:"row2";s:14:"Row 7 column 2";s:4:"row3";s:14:"Row 7 column 3";}i:8;a:4:{s:4:"row0";s:14:"Row 8 column 0";s:4:"row1";s:14:"Row 8 column 1";s:4:"row2";s:14:"Row 8 column 2";s:4:"row3";s:14:"Row 8 column 3";}i:9;a:4:{s:4:"row0";s:14:"Row 9 column 0";s:4:"row1";s:14:"Row 9 column 1";s:4:"row2";s:14:"Row 9 column 2";s:4:"row3";s:14:"Row 9 column 3";}i:10;a:4:{s:4:"row0";s:15:"Row 10 column 0";s:4:"row1";s:15:"Row 10 column 1";s:4:"row2";s:15:"Row 10 column 2";s:4:"row3";s:15:"Row 10 column 3";}i:11;a:4:{s:4:"row0";s:15:"Row 11 column 0";s:4:"row1";s:15:"Row 11 column 1";s:4:"row2";s:15:"Row 11 column 2";s:4:"row3";s:15:"Row 11 column 3";}i:12;a:4:{s:4:"row0";s:15:"Row 12 column 0";s:4:"row1";s:15:"Row 12 column 1";s:4:"row2";s:15:"Row 12 column 2";s:4:"row3";s:15:"Row 12 column 3";}i:13;a:4:{s:4:"row0";s:15:"Row 13 column 0";s:4:"row1";s:15:"Row 13 column 1";s:4:"row2";s:15:"Row 13 column 2";s:4:"row3";s:15:"Row 13 column 3";}i:14;a:4:{s:4:"row0";s:15:"Row 14 column 0";s:4:"row1";s:15:"Row 14 column 1";s:4:"row2";s:15:"Row 14 column 2";s:4:"row3";s:15:"Row 14 column 3";}i:15;a:4:{s:4:"row0";s:15:"Row 15 column 0";s:4:"row1";s:15:"Row 15 column 1";s:4:"row2";s:15:"Row 15 column 2";s:4:"row3";s:15:"Row 15 column 3";}i:16;a:4:{s:4:"row0";s:15:"Row 16 column 0";s:4:"row1";s:15:"Row 16 column 1";s:4:"row2";s:15:"Row 16 column 2";s:4:"row3";s:15:"Row 16 column 3";}i:17;a:4:{s:4:"row0";s:15:"Row 17 column 0";s:4:"row1";s:15:"Row 17 column 1";s:4:"row2";s:15:"Row 17 column 2";s:4:"row3";s:15:"Row 17 column 3";}i:18;a:4:{s:4:"row0";s:15:"Row 18 column 0";s:4:"row1";s:15:"Row 18 column 1";s:4:"row2";s:15:"Row 18 column 2";s:4:"row3";s:15:"Row 18 column 3";}i:19;a:4:{s:4:"row0";s:15:"Row 19 column 0";s:4:"row1";s:15:"Row 19 column 1";s:4:"row2";s:15:"Row 19 column 2";s:4:"row3";s:15:"Row 19 column 3";}}

(转发请注明转自:学PHP)    


  相关推荐



1楼 学phper说: 2016-03-15 02:03:00
-1'
2楼 学phper说: 2016-03-15 02:03:00
1
3楼 -1'说: 2016-03-15 02:03:02
1
4楼 学phper说: 2016-04-03 17:30:28
1
5楼 -1'说: 2016-04-03 17:30:29
1

  发表评论
昵称:
(不超过20个字符或10个汉字)
内容: