Title: PHP notice
Last modified: March 19, 2017

---

# PHP notice

 *  [Jacob N. Breetvelt](https://wordpress.org/support/users/opajaap/)
 * (@opajaap)
 * [9 years ago](https://wordpress.org/support/topic/php-notice-87/)
 * Query monitor reports this PHP error:
 *     ```
       Notice	Undefined property: stdClass::$slug	1	wp-content/plugins/php-code-for-posts/Classes/Snippet.php:19	
       ```
   
 * Stack trase:
 *     ```
       PhpCodeForPosts_Snippet::create_from_database_object()
       wp-content/plugins/php-code-for-posts/Classes/Database.php:92
       PhpCodeForPosts_Database::load_single_snippet()
       wp-content/plugins/php-code-for-posts/Classes/Shortcode.php:34
       PhpCodeForPosts_Shortcode::handle_shortcode()
       wp-includes/shortcodes.php:345
       do_shortcode_tag()
       Unknown location
       preg_replace_callback()
       wp-includes/shortcodes.php:223
       do_shortcode()
       wp-includes/class-wp-hook.php:298
       apply_filters('the_content')
       wp-includes/post-template.php:240
       the_content()
       wp-content/themes/virtue/templates/content-page.php:2
       load_template('~/wp-content/themes/virtue/templates/content-page.php')
       wp-includes/template.php:647
       locate_template()
       wp-includes/general-template.php:167
       get_template_part('templates/content','page')
       wp-content/themes/virtue/page.php:11	Plugin: php-code-for-posts
       ```
   
 * The php code from the snippet is executed.
    -  This topic was modified 9 years ago by [Jacob N. Breetvelt](https://wordpress.org/support/users/opajaap/).
    -  This topic was modified 9 years ago by [Jacob N. Breetvelt](https://wordpress.org/support/users/opajaap/).

The topic ‘PHP notice’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/php-code-for-posts_0d1022.svg)
 * [PHP Code for posts](https://wordpress.org/plugins/php-code-for-posts/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/php-code-for-posts/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/php-code-for-posts/)
 * [Active Topics](https://wordpress.org/support/plugin/php-code-for-posts/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/php-code-for-posts/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/php-code-for-posts/reviews/)

 * 2 replies
 * 3 participants
 * Last reply from: [LP9086](https://wordpress.org/support/users/lp9086/)
 * Last activity: [9 years ago](https://wordpress.org/support/topic/php-notice-87/#post-8955127)
 * Status: not resolved