Notice : Undefined index: sidebar_date
-
I found some notices while creating a post.
I have created a custom post type.
I want to create a post from this post type (/wp-admin/post-new.php?post_type=<my-cpt>), and get these logs on the create form :Undefined index: sidebar_date in /var/www/html/bedrock/web/app/plugins/post-expire-date-sidebar/expire.php on line 67 Notice: Undefined index: sidebar_drop in /var/www/html/bedrock/web/app/plugins/post-expire-date-sidebar/expire.php on line 68 Notice: Undefined index: sidebar_toogle in /var/www/html/bedrock/web/app/plugins/post-expire-date-sidebar/expire.php on line 71 Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/bedrock/web/app/plugins/post-expire-date-sidebar/expire.php:67) in /var/www/html/bedrock/web/wp/wp-admin/admin-header.php on line 9$metas = get_post_meta($id); $date = $metas['sidebar_date'][0];In my case,
var_dump( $metas )is an empty array, that’s why I found the notice log.Can you fix this please ?
Thank you for your help
The topic ‘Notice : Undefined index: sidebar_date’ is closed to new replies.