Promotion Slider
[resolved] Debug Mode reveals Undefined Variable on line 325 (3 posts)

  1. sstange
    Posted 4 years ago #

    Today I was testing changes made in my site by turning on the debug mode in the wp-config.php file using:

    define('WP_DEBUG', true);

    When I changed the parameter to "true" from the default "false" the following line started to display on my home page above the Promotion Slider (I'm showing the whole message and using "***" in place of my site that this is on):

    Notice: Undefined variable: promo_posts in /home/wshinc/public_html/*******.com/wp-content/plugins/promotion-slider/index.php on line 325

    This is line 325 in the index.php file:

    $promo_posts = apply_filters('promoslider_custom_query_results', $promo_posts);

    What is the fix so that this doesn't show up when Debug is on? I'm assuming that this points to an error or a conflict.


  2. kitan
    Posted 3 years ago #


    I had this same problem on my site...

    I solved it in a way that I removed this line of code

  3. Micah Wood
    Plugin Author

    Posted 3 years ago #

    Just change line 325 to read:

    $promo_posts = apply_filters( 'promoslider_custom_query_results', array() );

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Promotion Slider
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic