Bug: Page Title changes automatically after edit(steps to reproduce explained)
-
I see similar topics has been posted already but still no solution given so I’m posting this again with more technical details.
Nature of the Problem: After i edit any previously created page using Elementor, the page title changes automatically. Thing is it doesn’t happen when i create a new page using Elementor, but only happens when i edit any previously created page. Another thing is it doesn’t happen to all Elementor pages that’s why most of the users actually not seeing it.
After much investigation I found out that if any custom Elementor-Widget/shortcode contains the function
wp_reset_query()
and that Elementor-Widget/shortcode is used in any page, then that page is affected by this problem.How to reproduce the issue: Create a custom Elementor-Widget which contains the code like this below:
<?php $args = array(); $query = new WP_Query( $args ); ?> <?php if ( $query->have_posts() ) :?> <?php while ( $query->have_posts() ) : $query->the_post();?> <?php endwhile;?> <?php endif;?> <?php wp_reset_query();?>
And if you use this Widget in any page then that page will be affected.
Since this is a valid query and Elementor acts weird with this query, I think its a bug Elementor should fix.
- The topic ‘Bug: Page Title changes automatically after edit(steps to reproduce explained)’ is closed to new replies.