Title: [Plugin: WordPress Popular Posts] Show custom fields content
Last modified: August 20, 2016

---

# [Plugin: WordPress Popular Posts] Show custom fields content

 *  [drgoettel](https://wordpress.org/support/users/drgoettel/)
 * (@drgoettel)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-wordpress-popular-posts-show-custom-fields-content/)
 * Hello.
 * I’d like to know if it’s possible to add a custom field content to the output
   or if someone could give a clue of how to do it.
 * Great plugin! Thankyou for it
 * Andrés
 * [http://wordpress.org/extend/plugins/wordpress-popular-posts/](http://wordpress.org/extend/plugins/wordpress-popular-posts/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Thread Starter [drgoettel](https://wordpress.org/support/users/drgoettel/)
 * (@drgoettel)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-wordpress-popular-posts-show-custom-fields-content/#post-3109138)
 * I found a way to do it but I didn’t wanted to touch the plugin core.
 * This is what i did:
    line 1114: array_push($posts_data, $data); After this you
   can get any custom field with: $custom_field_value=get_post_meta($p->id,”custom_field_name”,
   true);
 * Don’t forget to change “custom_field_name” with your custom field name 🙂
 * If anyone knows how to do it without changing the plugin code… I would be very
   pleased
 * Andrés
 *  Plugin Author [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * (@hcabrera)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-wordpress-popular-posts-show-custom-fields-content/#post-3109207)
 * Hi Andrés,
 * No, unfortunately there’s no way to achieve that without hacking the plugin. 
   Anyways, thanks for sharing your solution, hopefully it’ll help others wanting
   to do the same.
 * Cheers!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘[Plugin: WordPress Popular Posts] Show custom fields content’ is closed
to new replies.

 * ![](https://ps.w.org/wordpress-popular-posts/assets/icon-256x256.png?rev=1232659)
 * [WP Popular Posts](https://wordpress.org/plugins/wordpress-popular-posts/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordpress-popular-posts/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordpress-popular-posts/)
 * [Active Topics](https://wordpress.org/support/plugin/wordpress-popular-posts/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordpress-popular-posts/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordpress-popular-posts/reviews/)

## Tags

 * [custom fields](https://wordpress.org/support/topic-tag/custom-fields/)

 * 2 replies
 * 2 participants
 * Last reply from: [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * Last activity: [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-wordpress-popular-posts-show-custom-fields-content/#post-3109207)
 * Status: not resolved