mirror of
git://develop.git.wordpress.org/
synced 2025-02-27 18:13:00 +01:00
Allow orberby in wp_list_bookmarks to accept a comma-delimited list of fields, per docs. fixes #12421, props sorich87, scribu.
git-svn-id: https://develop.svn.wordpress.org/trunk@14131 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
b0293c96f9
commit
8d47975e76
@ -221,7 +221,10 @@ function get_bookmarks($args = '') {
|
||||
$orderby = 'rand()';
|
||||
break;
|
||||
default:
|
||||
$orderby = "link_" . $orderby;
|
||||
$orderparams = array();
|
||||
foreach ( explode(',', $orderby) as $ordparam )
|
||||
$orderparams[] = 'link_' . trim($ordparam);
|
||||
$orderby = implode(',', $orderparams);
|
||||
}
|
||||
|
||||
if ( 'link_id' == $orderby )
|
||||
|
Loading…
x
Reference in New Issue
Block a user