Add name_like query to get_terms(). Use it in suggestCategories.
git-svn-id: http://svn.automattic.com/wordpress/trunk@5756 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -546,13 +546,7 @@ class wp_xmlrpc_server extends IXR_Server {
|
||||
$limit = "LIMIT {$max_results}";
|
||||
}
|
||||
|
||||
$category_suggestions = $wpdb->get_results("
|
||||
SELECT cat_ID category_id,
|
||||
cat_name category_name
|
||||
FROM {$wpdb->categories}
|
||||
WHERE cat_name LIKE '{$category}%'
|
||||
{$limit}
|
||||
");
|
||||
$category_suggestions = get_categories("get=all&number=$max_results&name_like=$category");
|
||||
|
||||
return($category_suggestions);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user