Home > php教程 > php手册 > PHP数组排序函数

PHP数组排序函数

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 11:34:58
Original
916 people have browsed it

sort:本函数为 array 中的单元赋予新的键名。这将删除原有的键名而不仅是重新排序。

rsort:本函数对数组进行逆向排序(最高到最低)。 删除原有的键名而不仅是重新排序。

asort:对数组进行排序并保持索引关系

arsort:对数组进行逆向排序并保持索引关系

ksort:对数组按照键名排序,保留键名到数据的关联

krsort:对数组按照键名逆向排序,保留键名到数据的关联

natsort:对字母数字字符串进行排序并保持原有键/值的关联

natcasesort:同natsort排序算法,但不区分大小写字母排序

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
php data acquisition?
From 1970-01-01 08:00:00
0
0
0
PHP extension intl
From 1970-01-01 08:00:00
0
0
0
How to learn php well
From 1970-01-01 08:00:00
0
0
0
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template