Support » Plugin: Advanced Browser Check » Invalid argument in output.php

  • Resolved gsingh93

    (@gsingh93)


    Whenever the plugin detects an older browser, it displays the popup correctly but at the top of the screen it shows me an error that looks something like “Warning: Invalid argument supplied for foreach() in …/advanced-browser-check/output.php on line 37”. I looked at that line of code and did some debugging but couldn’t find anything wrong with it.

    Do you see this error? Do you have any idea what’s causing it?

    http://wordpress.org/extend/plugins/advanced-browser-check/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Mattias

    (@darkwhispering)

    Hi,

    Thanks for the report, I will look into this.

    Plugin Author Mattias

    (@darkwhispering)

    Hi again,

    I have looked thought the code and I can’t replicate your problem.

    What browser are you getting this error in? What version of the plugin are you using? and what settings do you have on the settings page?

    Thanks

    Hi,

    I tested this on both my local machine and on my live site and it only occurs on my live site. One major difference that I know of between the two is the live site is the version of PHP. Here is the output of php –version for my live site:
    PHP 5.2.17 (cli) (built: Feb 1 2012 15:01:30)
    Copyright (c) 1997-2010 The PHP Group
    Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
    with the ionCube PHP Loader v4.2.2, Copyright (c) 2002-2012, by ionCube Ltd., and
    with Zend Optimizer v3.3.9, Copyright (c) 1998-2009, by Zend Technologies

    and here is the output for my local machine
    PHP 5.3.10-1ubuntu3.4 with Suhosin-Patch (cli) (built: Sep 12 2012 18:59:41)
    Copyright (c) 1997-2012 The PHP Group
    Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies

    The important part I think is the live site uses PHP 5.2. Do you do anything that wouldn’t work in PHP 5.2?

    And to answer your questions, this happens in every browser that is below the threshold, both desktop and mobile. I’m using the latest version of the plugin. And for settings, I’ve selected to allow the user to hide the popup, link no browsers, and the settings for the browsers don’t really matter, it happens on every browser I try (I just make each setting max to test my current browser, chrome 23).

    Plugin Author Mattias

    (@darkwhispering)

    Hi again,

    yes, your getting the error due to that your server is running php 5.2 as my plugin require php 5.3 (I should mention that somewhere in my description about the plugin).

    If you can, I really recommend you to update your web server to php 5.3

    Hi,

    I updated my webserver to PHP 5.3.15 and I’m still experienced the error. Does the plugin require a newer version than this?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Invalid argument in output.php’ is closed to new replies.