Title: PUM Shortcode Full Functionality with Custom Post Types
Last modified: August 11, 2021

---

# PUM Shortcode Full Functionality with Custom Post Types

 *  Resolved [beingtree](https://wordpress.org/support/users/beingtree/)
 * (@beingtree)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/pum-shortcode-full-functionality-with-custom-post-types/)
 * This is just to help anyone else who needs the same functionality I did.
 * Currently, the PUM shortcode button only shows “Popup Cookie” when you’re on 
   a custom post type. There is a filter you can hook into to make PUM shortcode
   fully functional on custom post types: `pum_shortcode_post_types`.
 * Here is a generic version of my implemmentation (put it in your theme’s functions
   file):
 *     ```
       /* Add full Popup Maker shortcode functionality to ustom post types */
       	function theme_name_product_pum_shortcode($pum_post_types) {
       		$pum_post_types[] = 'product'; // this is the WooCommerce Product post type
       		/*
       		  If you want to add to multiple, just add more lines like the above, using the appropriate post type names.
   
       		If you need to add to a lot of post types, you could make an array, and use array_merge.
       		*/
       		return $pum_post_types;
       	}
   
       	add_filter('pum_shortcode_post_types', theme_name_product_pum_shortcode');
       ```
   
    -  This topic was modified 4 years, 9 months ago by [beingtree](https://wordpress.org/support/users/beingtree/).

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

 *  [Bel](https://wordpress.org/support/users/belimperial/)
 * (@belimperial)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/pum-shortcode-full-functionality-with-custom-post-types/#post-14763383)
 * Hi [@beingtree](https://wordpress.org/support/users/beingtree/)
 * Thank you for sharing this information.
 * I was checking the code for WooCommerce product editor and it appears it is missing
   a single quote in the add_filter – ‘theme_name_product_pum_shortcode’.
 * Here’s the updated code:
 *     ```
       /* Add full Popup Maker shortcode functionality to ustom post types */
       	function theme_name_product_pum_shortcode($pum_post_types) {
       		$pum_post_types[] = 'product'; // this is the WooCommerce Product post type
       		/*
       		  If you want to add to multiple, just add more lines like the above, using the appropriate post type names.
       		If you need to add to a lot of post types, you could make an array, and use array_merge.
       		*/
       		return $pum_post_types;
       	}
   
       	add_filter('pum_shortcode_post_types', 'theme_name_product_pum_shortcode');
       ```
   
 * Everything is perfect with the code. Thank you for sharing this.
 *  Thread Starter [beingtree](https://wordpress.org/support/users/beingtree/)
 * (@beingtree)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/pum-shortcode-full-functionality-with-custom-post-types/#post-14764905)
 * [@belimperial](https://wordpress.org/support/users/belimperial/), Woops! Thanks
   for catching that. I think when I “generic-ified” it, I must’ve deleted the quote
   🙂
 *  [Maria T](https://wordpress.org/support/users/mariatogonon/)
 * (@mariatogonon)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/pum-shortcode-full-functionality-with-custom-post-types/#post-14771764)
 * Hi there [@beingtree](https://wordpress.org/support/users/beingtree/), on behalf
   of Bel you are welcome! 😊
 * By the way, if you have a moment then we would very much appreciate it if you
   could quickly [rate the plugin](https://wordpress.org/support/plugin/popup-maker/reviews/?rate=5#rate-response),
   just to help us spread the word.
 * Have a great day & keep safe!

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

The topic ‘PUM Shortcode Full Functionality with Custom Post Types’ is closed to
new replies.

 * ![](https://ps.w.org/popup-maker/assets/icon-256x256.gif?rev=3097653)
 * [Popup Maker - Boost Sales, Conversions, Optins, Subscribers with the Ultimate WP Popup Builder](https://wordpress.org/plugins/popup-maker/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/popup-maker/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/popup-maker/)
 * [Active Topics](https://wordpress.org/support/plugin/popup-maker/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/popup-maker/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/popup-maker/reviews/)

## Tags

 * [mce](https://wordpress.org/support/topic-tag/mce/)
 * [shortcode](https://wordpress.org/support/topic-tag/shortcode/)

 * 3 replies
 * 3 participants
 * Last reply from: [Maria T](https://wordpress.org/support/users/mariatogonon/)
 * Last activity: [4 years, 9 months ago](https://wordpress.org/support/topic/pum-shortcode-full-functionality-with-custom-post-types/#post-14771764)
 * Status: resolved