Title: PHP codes (and widget) documentation
Last modified: August 21, 2016

---

# PHP codes (and widget) documentation

 *  [Thomas Schmall](https://wordpress.org/support/users/oxpal/)
 * (@oxpal)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/php-codes-and-widget-documentation/)
 * I’m looking for hours for documentation on PHP codes for putting WooCommerce 
   features or widgets into my page. For example integrating the featured products.
   I suppose (since I’m a beginner on this) I’m doing something nobody else seems
   to try…
    So this is not so much an urgent support request – more sharing my user
   experience – and either pointing out lacking documentation, or maybe getting 
   a hint to what I’m missing here.
 * My thinking first was that I just add a PHP code – as in
    WC_Widget_Featured_Products();
   Well, finding this PHP function took me ages, I couldn’t find it on the WooCommerce
   user guide, nor via google. I still can’t find any list of functions for the 
   other widgets – nor a list of arguments I could enter.
 * Next i thought I go via the_widget. But again, google turns up no list of PHP
   codes those widgets – only much more complicated support issues.
    There is a 
   list of Widgets included with WooCommerce – but that one is not stating PHP names.
   Nor arguments. So when I tried the name from the function name from above (WC_Widget_Featured_Products)
   it seems to work: the_widget(‘WC_Widget_Featured_Products’, ‘per_page=1’); …But
   the arguments don’t seem to get applied. I got the “per_page 1” from the shortcodes
   list, so I assumed it would work.
 * Any hint of how to go about it? Basically I just want to add WooCommerce features
   in my theme without using shortcodes (since these only work in pages/posts).
 * [http://wordpress.org/extend/plugins/woocommerce/](http://wordpress.org/extend/plugins/woocommerce/)

The topic ‘PHP codes (and widget) documentation’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [Thomas Schmall](https://wordpress.org/support/users/oxpal/)
 * Last activity: [12 years, 11 months ago](https://wordpress.org/support/topic/php-codes-and-widget-documentation/)
 * Status: not resolved