Title: Call WPP Widget by using PHP
Last modified: November 27, 2020

---

# Call WPP Widget by using PHP

 *  Resolved [hing02](https://wordpress.org/support/users/hing02/)
 * (@hing02)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/call-wpp-widget-by-using-php/)
 * Any way to use php or shortcode to call the WPP Widget ? I have a mobile theme,
   which use optimized for AMP and mobile use, in order to keep the best speed, 
   it will take all the widget out. The only way to insert the widget is put the
   php/shortcode in the footer.

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

 *  Thread Starter [hing02](https://wordpress.org/support/users/hing02/)
 * (@hing02)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/call-wpp-widget-by-using-php/#post-13718142)
 * I’ve try adding shortcode, it can work, but without thumbnail. How can I use 
   shortcode to display just like widget with thumbnail?
 * [wpp range=’custom’ time_unit=’HOUR’ time_quantity=1 order_by=’views’ stats_comments
   =1 wpp_start=’
    1. ‘ wpp_end=’
 * ‘]
 *  Plugin Author [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * (@hcabrera)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/call-wpp-widget-by-using-php/#post-13718269)
 * Hi [@hing02](https://wordpress.org/support/users/hing02/),
 * I’m sure there’s a way to do this but personally I have never attempted it. Maybe
   someone else reading this might be able to help.
 *  Plugin Author [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * (@hcabrera)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/call-wpp-widget-by-using-php/#post-13718291)
 * Oh, I skipped your second comment!
 * To have the shortcode display the post thumbnails you must set the width & height
   of the images using the thumbnail_width and thumbnail_height parameters.
 * For example:
 * `[wpp thumbnail_width=100 thumbnail_height=75 post_html='<li>{thumb} <a href="{
   url}">{text_title}</a></li>']`

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

The topic ‘Call WPP Widget by using PHP’ 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/)

 * 3 replies
 * 2 participants
 * Last reply from: [Hector Cabrera](https://wordpress.org/support/users/hcabrera/)
 * Last activity: [5 years, 7 months ago](https://wordpress.org/support/topic/call-wpp-widget-by-using-php/#post-13718291)
 * Status: resolved