Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/279.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/list/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
在PHP和MYSQL中按顺序排序和保存的项目列表_Php_Jquery_Mysql - Fatal编程技术网

在PHP和MYSQL中按顺序排序和保存的项目列表

在PHP和MYSQL中按顺序排序和保存的项目列表,php,jquery,mysql,Php,Jquery,Mysql,假设我有一个名为shopping_items的表,每个购物项目都属于一个id(拥有购物项目的人) 在一个页面上,我将有一个可排序的jquery,它按照位置的顺序显示person 10中的项目,但我希望它是动态的,并且需要保存排序中的每个更改 存储此类数据并使可排序功能正常工作的最佳方法是什么?可能会帮助您使用过数据表吗?可能有帮助您是否使用过数据表? ID | ID_PERSON | ITEM | POSITION 1 | 10 | test | 3 1 | 10

假设我有一个名为shopping_items的表,每个购物项目都属于一个id(拥有购物项目的人)

在一个页面上,我将有一个可排序的jquery,它按照位置的顺序显示person 10中的项目,但我希望它是动态的,并且需要保存排序中的每个更改


存储此类数据并使可排序功能正常工作的最佳方法是什么?

可能会帮助您使用过数据表吗?可能有帮助您是否使用过数据表?
ID | ID_PERSON | ITEM | POSITION
1  | 10        | test | 3
1  | 10        | tes2 | 2
1  | 21        | tes3 | 3
1  | 10        | tes4 | 8
1  | 10        | tes5 | 10