• How do I stop Polylang working within a custom WP_Query?
    I am trying this

    $language = get_post_language(XX);
    $args = array(
    ‘post_type’ => ‘any’,
    ‘p’=> XX,
    ‘language’ => $language,
    )
    but the WP_Query is returning the translation for the current page language. How do I disable polylang translation in this instance?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Chouby

    (@chouby)

    Hello,

    This should answer your question: https://polylang.pro/doc/developpers-how-to/#all

    coonvo

    (@coonvo)

    Hi, I have a list of items as custom post type, also I have a function by dynamic ooo to add them to the favorites list. Unfortunately, none of them are showing up in favorites list since I installed polling. Ho do I make them show up on any language without translating them?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘disable translation in wp_query’ is closed to new replies.