Created
October 17, 2012 07:39
-
-
Save zourbuth/3904247 to your computer and use it in GitHub Desktop.
Get All WordPress User Meta Keys
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Returns all unique meta key from user meta database | |
* | |
* @param no parameter right now | |
* @retun std Class | |
* @todo do what you do for each meta key. | |
*/ | |
function get_user_meta_key() { | |
global $wpdb; | |
$select = "SELECT distinct $wpdb->usermeta.meta_key FROM $wpdb->usermeta"; | |
$usermeta = $wpdb->get_results($select); | |
return $usermeta; | |
} |
mehdi-eybak
commented
Nov 15, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment