Title: Polylang support not working
Last modified: August 9, 2017

---

# Polylang support not working

 *  anonymized-14020573
 * (@anonymized-14020573)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/polylang-support-not-working/)
 * The popups are not translatable. If I make them translatable with adding the 
   following script to functions.php, still popups in all languages appear at the
   same time (under each language).
 * // PopUp CPT translataple
    add_filter( ‘pll_get_post_types’, ‘add_cpt_to_pll’,
   10, 2 ); function add_cpt_to_pll( $post_types, $is_settings ) { if ( $is_settings){//
   hides ‘popups’ from the list of custom post types in Polylang settings unset(
   $post_types[‘spucpt’] ); } else { // enables language and translation management
   for ‘popups’ $post_types[‘spucpt’] = ‘spucpt’; } return $post_types; }

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

 *  Plugin Author [Damian](https://wordpress.org/support/users/timersys/)
 * (@timersys)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9408054)
 * You have latest version of the popups plugin?
 *  Thread Starter anonymized-14020573
 * (@anonymized-14020573)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9408986)
 * Yes i have the latest version.
 *  Thread Starter anonymized-14020573
 * (@anonymized-14020573)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9468576)
 * Any update on this matter?
 * Thanks,
    Henri
 *  Plugin Author [Damian](https://wordpress.org/support/users/timersys/)
 * (@timersys)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9472754)
 * HI Henri, sorry for the delay. I just tried locally and I only see the popups
   in the desired language.
 * I have popup A in english and spanish and I have popup B just in english.
 * I added a language switcher on the sidebar and when I visit the english version
   I see popup A and B and when I check spanish version I only see popup A.
 * Could be the rules or something else?
 *  Thread Starter anonymized-14020573
 * (@anonymized-14020573)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9515880)
 * The rules I have are following: “Page Type” “is equal to” “All Pages” AND “Mobile
   Phone” “is not equal to” “True”.
 * Also I need to add code to functions.php to enable translations for PopUp-s. 
   It is not enabled by the plugin itself.
    The code I added to functions.php is
   the following:
 *     ```
       add_filter( 'pll_get_post_types', 'add_cpt_to_pll', 10, 2 );
       function add_cpt_to_pll( $post_types, $is_settings ) {
       	if ( $is_settings ) {
       		// hides ‘popups’ from the list of custom post types in Polylang settings
       		unset( $post_types['spucpt'] );
       	} else {
       		// enables language and translation management for ‘popups’
       		$post_types['spucpt'] = 'spucpt';
       	}
       	return $post_types;
       }
       ```
   
 *  Plugin Author [Damian](https://wordpress.org/support/users/timersys/)
 * (@timersys)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9517224)
 * The rules and code looks fine to me. Try disable all plugins (except polylang)
   to see if any is affecting.

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

The topic ‘Polylang support not working’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/popups_efeef0.svg)
 * [Popups - WordPress Popup](https://wordpress.org/plugins/popups/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/popups/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/popups/)
 * [Active Topics](https://wordpress.org/support/plugin/popups/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/popups/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/popups/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [Damian](https://wordpress.org/support/users/timersys/)
 * Last activity: [8 years, 7 months ago](https://wordpress.org/support/topic/polylang-support-not-working/#post-9517224)
 * Status: not resolved