• Resolved klucas0406

    (@klucas0406)


    I am getting the following error at the top of my site:

    Warning: Invalid argument supplied for foreach() in /home/ccchso5/public_html/wp-content/plugins/popup-builder/com/classes/components/Menu.php on line 157

    Please help.

    ### Start System Info ###
    
    -- Site Info
    
    Site URL:                 https://www.ccchs.org
    Home URL:                 https://www.ccchs.org
    Multisite:                No
    
    -- Hosting Provider
    
    Host:                     DBH: localhost, SRV: www.ccchs.org
    
    -- User Browser
    
    Platform:           Windows
    Browser Name:       Google Chrome
    Browser Version:    89.0.4389.82
    User Agent:         Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.82 Safari/537.36
    
    -- WordPress Configuration
    
    Version:                  5.6.2
    Language:                 en_US
    Permalink Structure:      /%postname%/
    Active Theme:             Avada Child 1.0.0
    Show On Front:            page
    Page On Front:            Clearwater Central Catholic High School (#7137)
    Page For Posts:           Blog (#7330)
    Table Prefix:             Prefix: wp_  Length: 3   Status: Acceptable
    WP_DEBUG:                 Disabled
    Memory Limit:             96M
    Registered Post Stati:    publish, future, draft, pending, private, trash, auto-draft, inherit, request-pending, request-confirmed, request-failed, request-completed
    
    -- Popup Builder License Data
    
    -- All created Popups
    
    Id:     11032
    Title:  COVID-19 Update
    Type:   html
    Status: Enabled
    
    -- WordPress Active Plugins
    
    3D FlipBook - Lite Edition: 1.10.16
    Advanced Editor Tools (previously TinyMCE Advanced): 5.6.0
    All in one Favicon: 4.7
    Avada Builder: 3.2.1
    Avada Core: 5.2.1
    BackupBuddy: 8.7.2.0
    Custom Login: 3.2.11
    Gravity Forms: 2.4.23
    JDM's Print CSS: 1.5
    LayerSlider WP: 6.11.5
    Media Cleaner: 6.1.5
    Menu Management Enhancer: 1.1
    MouseWheel Smooth Scroll: 5.5
    Page Links To: 3.3.5
    PayPal Donations: 1.9.6
    Popup Builder: 3.77
    Post Types Order: 1.9.5.5
    Shortcodes Ultimate: 5.9.8
    Simple 301 Redirects: 1.07
    Smush: 3.8.3
    Staff List Pro: 3.5.5
    Wordfence Security: 7.4.14
    WP 404 Auto Redirect to Similar Post: 1.0.3
    WP Dashboard Notes: 1.0.10
    WPS Hide Login: 1.8.5
    WP Super Cache: 1.7.1
    Yoast SEO: 15.9.1
    
    -- WordPress Inactive Plugins
    
    -- Webserver Configuration
    
    PHP Version:              7.4.15
    MySQL Version:            5.5.5
    Webserver Info:           Apache
    
    -- PHP Configuration
    
    Memory Limit:             512M
    Upload Max Size:          128M
    Post Max Size:            128M
    Upload Max Filesize:      128M
    Time Limit:               10000
    Max Input Vars:           10000
    Display Errors:           On (1)
    
    -- PHP Extensions
    
    cURL:                     Supported
    fsockopen:                Supported
    SOAP Client:              Installed
    Suhosin:                  Not Installed
    
    -- Session Configuration
    
    Session:                  Disabled
    Platform:           
    Browser Name:       
    Browser Version:    
    User Agent:         
    
    ### End System Info ###
    • This topic was modified 4 years ago by klucas0406.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • clickingclients

    (@clickingclients)

    I have the same issue on update to Version 3.77.
    It errors when foreach is trying to access empty array on line 157.
    Please add the check and update the code soon:
    if(!empty($menuItems)){

    public function getNavMenuItemsWithPopup($navMenuLocations = array(), $forceUpdate = false)
        {
    		if (!isset(self::$navMenuItems) && !$forceUpdate) {
    			foreach ($navMenuLocations as $menuName => $menuId) {
    				$menuItems = wp_get_nav_menu_items($menuId);
    				if(!empty($menuItems)){
    					foreach ($menuItems as $menuItem) {
    						$popupId = $menuItem->sgpbPopupId;
    						if ($popupId > 0) {
    							self::$navMenuItems[] = $menuItem;
    						}
    					}
    				}
    			}
    		}
    
    		return isset(self::$navMenuItems) ? self::$navMenuItems : array();
    	}
    birdsflyfree

    (@birdsflyfree)

    I have the same error:

    Warning: Invalid argument supplied for foreach() in /home/customer/www/stoodleighcourtcoachhouse.co.uk/public_html/wp-content/plugins/popup-builder/com/classes/components/Menu.php on line 157

    Please fix ASAP

    Sygnoos Support

    (@sygnoossupport)

    Dear @klucas0406 and @clickingclients ,

    Thanks for reporting.
    This is to inform you, that the issue is solved with the latest 3.78 version of the plugin.
    Please, update it and let us know if that helped.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘PHP Error’ is closed to new replies.