How to fetch records from database WordPress
wpdb is a simple wrapper around the mysql_* functions, but you can’t mix and match them. $wpdb->query does not return the database reference that mysql_fetch_row needs. It … … returns an integer corresponding to the number of rows affected/selected. If there is a MySQL error, the function will return FALSE. (Note: since both 0 and … Read more