• Hello,
    I use Cyclone Slider 2 and WPML for internationalization. I translated slides in 4 languages. FR, EN, DE, IT. The main language is French.
    Here is my problem : when I’m on the main language homepage, the slider always displays in german instead of french. When I switch to another language, the slide in the correct language is displayed. German is the last translation I did.

    I investigated and it led me to this function get_slider_by_slug which fetch posts.
    I saw the argument to fetch only posts in the expected language was not in it.

    I added 'suppress_filters' => false
    So this :

    $args = array(
                    'post_type' => 'cycloneslider',
                    'numberposts' => 1,
                    'name'=> $slug
                );

    become this :

    $args = array(
                    'post_type' => 'cycloneslider',
                    'numberposts' => 1,
                    'name'=> $slug,
                    'suppress_filters' => false
                );

    And it works. But it’s bad to modify your plugin so I wanted to know if there is an other way, or if there is a possible correction ?
    Did this bug affect someone else ? Can you reproduce it ?

    Thanks a lot for your answer.
    Lucile

    http://wordpress.org/plugins/cyclone-slider-2/

Viewing 3 replies - 1 through 3 (of 3 total)
  • I have the same issue i think.. I’m using WPML plugin for site languages and default language is different from english. For some reason all sliders in all languages links to english slider links.
    Adding line “‘suppress_filters’ => false” helped me a lot ! Thank you for that!

    Hope the issue will be solved soon

    Hi,
    I have the same problem, but
    In what file is that function?
    Many thanks

    Thread Starter ldaguise

    (@ldaguise)

    Hello,
    The method get_slider_by_slug is in :
    cyclone-slider-2/classes/class-cyclone-slider-data.php

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WPML compatibility bug’ is closed to new replies.