note 80592 added to function.sort
| From: | matpatnikathotmaildotcom at osu1 dot php dot net | Date: | Wed, 23 Jan 2008 23:46:04 +0000 |
| Subject: | note 80592 added to function.sort | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-135357@lists.php.net to get a copy of this message | ||
This function will sort entity letters eg:é
I hope that help someone
function sort_entity($array) {
$total = count($array);
for ($i=0;$i<$total;$i++) {
if ($array[$i]{0} == '&') {
$array[$i] = $array[$i]{1}.$array[$i];
} else {
$array[$i] = $array[$i]{0}.$array[$i];
}
}
sort($array);
for ($i=0;$i<$total;$i++) {
$array[$i] = substr($array[$i],1);
}
return $array;
}
----
Server IP: 66.207.199.35
Probable Submitter: 24.67.100.155
----
Manual Page -- http://www.php.net/manual/en/function.sort.php
Edit -- https://master.php.net/note/edit/80592
Del: integrated -- https://master.php.net/note/delete/80592/integrated
Del: useless -- https://master.php.net/note/delete/80592/useless
Del: bad code -- https://master.php.net/note/delete/80592/bad+code
Del: spam -- https://master.php.net/note/delete/80592/spam
Del: non-english -- https://master.php.net/note/delete/80592/non-english
Del: in docs -- https://master.php.net/note/delete/80592/in+docs
Del: other reasons-- https://master.php.net/note/delete/80592
Reject -- https://master.php.net/note/reject/80592
Search -- https://master.php.net/manage/user-notes.php