Elementor changes get_query_var
-
calling $post_type_name = get_query_var( ‘post_type’ ); when elementor is active returns a array even in pages that are not using elementor. This is incorrect !!!
<small></small> <b>array</b> <i>(size=3)</i> 0 <font color="#888a85">=></font> <small>string</small> <font color="#cc0000">'post'</font> <i>(length=4)</i> 1 <font color="#888a85">=></font> <small>string</small> <font color="#cc0000">'page'</font> <i>(length=4)</i> 2 <font color="#888a85">=></font> <small>string</small> <font color="#cc0000">'e-landing-page'</font> <i>(length=14)</i>
array (size=3)
0 => string ‘post’ (length=4)
1 => string ‘page’ (length=4)
2 => string ‘e-landing-page’This message shows in pages and posts that have been created or saved after elementor was activated. Even if they are not elementor pages.
Theme developers are expecting a post_type to be returned not a array !
This is incorrect. It should never show that message on not elementor pages. How can i turn off that behavior. I dont want a array returned i need the post type returned !
- The topic ‘Elementor changes get_query_var’ is closed to new replies.