I am using wordpress version 5.32 and elementor plugin (2.8)
While i am trying to customize and publish it raise an issue like:
<b>Notice</b>
: Trying to get property 'ID' of non-object in
<b>/wordpress/wp-includes/post.php</b>
on line <b>6534</b>
<br />
Line 6534:
function update_post_cache( &$posts ) {
if ( ! $posts ) {
return;
}
foreach ( $posts as $post ) {
wp_cache_add( $post->ID, $post, 'posts' );
}
}
and the change not geting updated in the website.
Disabling the elementor plugin will resolve this problem. How can i fix this issue with elementor plugin.
3
Answers
Instead of
you can use:
Try this
Hope this helps :
I had a siliar issue, I noticed that in de database, the table
wp_posts
had entries with theID
that had a value of0
.I deleted those entrys and added an
AUTO_INCREMENT
(that for some reason was not set) to theID
row of that table