Replacing the deprecated function the_meta
You can use get_metadata() to retrieve all meta data for a post, by leaving the third and fourth parameters empty. $meta_key string Optional Metadata key. If not specified, retrieve all metadata for the specified object. get_metadata( ‘post’, $post_id );