mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
Replace all uses of like_escape() with $wpdb->esc_like().
Props miqrogroove. See #10041. git-svn-id: https://develop.svn.wordpress.org/trunk@28712 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -632,14 +632,14 @@ function meta_form( $post = null ) {
|
||||
*
|
||||
* @param int $limit Number of custom fields to retrieve. Default 30.
|
||||
*/
|
||||
$limit = (int) apply_filters( 'postmeta_form_limit', 30 );
|
||||
$keys = $wpdb->get_col( "
|
||||
SELECT meta_key
|
||||
$limit = apply_filters( 'postmeta_form_limit', 30 );
|
||||
$sql = "SELECT meta_key
|
||||
FROM $wpdb->postmeta
|
||||
GROUP BY meta_key
|
||||
HAVING meta_key NOT LIKE '\_%'
|
||||
HAVING meta_key NOT LIKE %s
|
||||
ORDER BY meta_key
|
||||
LIMIT $limit" );
|
||||
LIMIT %d";
|
||||
$keys = $wpdb->get_col( $wpdb->prepare( $sql, $wpdb->esc_like( '_' ) . '%', $limit ) );
|
||||
if ( $keys ) {
|
||||
natcasesort( $keys );
|
||||
$meta_key_input_id = 'metakeyselect';
|
||||
|
||||
Reference in New Issue
Block a user