Viewing 15 replies - 1 through 15 (of 23 total)
  • Plugin Contributor responsivemenu

    (@responsivemenu)

    P.S – If anyone has a server failing with this issue I would like FTP access to someones setup so I can see if I can create a catch for this error and provide a useful error message instead.

    I am willing to give a free Pro license in return.

    All the best

    Hey –

    Just wanted to try and help provide more information as you diagnose. We are running PHP 5.4.24 and experiencing this error – so I don’t think it’s entirely related to the outdated PHP version.

    I also get a fatal error trying to enable the plugin on a sandbox WordPress WAMP site, no plugins installed, 2016 theme, PHP 5.5.12

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Hi Spencer,

    Is there any way to get access to that box as I was almost 100% sure it was due to anonymous functions in PHP 5.3 and below but obviously you’ve just disproved that.

    Sorry, I would but I can’t give access to that site, only because I manage it for a client. But if you just spin off a sandbox/local WP instance, and activate only the plugin, you should be able to replicate it.

    If not let me know, I can host a sandbox server on a subdomain somewhere.

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Hi Spencer,

    I will try and find a local box with PHP 5.4.24 somewhere and try and play around with it.

    Do you get the same fatal error on the site with PHP 5.5.12 installed?

    Everywhere I have searched on the web says that the error above is definetely for people below 5.4 so I’m tearing my hair out at the moment trying to work this one out!

    Can you triple confirm that those are the actual versions of PHP you are using.

    For example simply do:

    <?php echo PHP_VERSION; ?>

    anywhere on your site and let me know what the output of that is?

    Thanks for all your help

    this one says where the error is happening ‘line 16’ if that helps ..
    Parse error: syntax error, unexpected ‘[‘ in /httpdocs/wordpress/wp-content/plugins/responsive-menu/src/app/Routing/WpRouting.php on line 16

    I apologize – the <?php phpinfo(); ?> shows me that site is running PHP 5.2. Strangely the cpanel said otherwise.

    And I noticed I’m getting a different error running on a sandbox site (which I can confirm is PHP 5.5.12):

    ( ! ) Warning: array_key_exists() expects parameter 2 to be array, null given in L:\wamp\www\sandbox2\wp-content\plugins\responsive-menu\src\app\Collections\OptionsCollection.php on line 63

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Hi spencer,

    That second issue is something else that is fixed in the newest release.

    I am sure it is a 5.3 and below error (man 5.2 is super old!) but my plugin is supposed to disable itself whenever a PHP version is below 5.4 and that’s what’s worrying me more.

    What version of my plugin do you have installed currently? Can you try and update to the latest (3.0.5) if you havent already and tell me if the plugin still doesn’t deactivate itself in the admin area?

    Thanks again for the help

    Hi Responsive Menu,
    at my local test environment – which I’m running on top of AMPPS and using PHP 5.3 because of a very versatile theme development tool requiring it.

    When I updated Responsive Menu to the newest 3.0.5 version, a parse error appeared and neither the admin side of WP nor the test site itself did not work at all. Then I deleted Responsive Menu and reinstalled it as a totally new plugin and it did not activate but displayed a text telling “could not activate the plugin as it caused an error”. Now the local test side works fine – but without Responsive Menu. But obviously Responsive Menu installation works as it should, preventing a parse error and closure of the site in total.

    Looks like I need to find a way to run two local environments – one with PHP 5.3. and another with the newest PHP versions.

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Hi Vesa,

    This is annoying me because I have done everything I can think of to stop it creating parse errors and fatal errors when the wrong PHP version is installed.

    Im not sure if its an actual limitation of PHP itself in PHP 5.3 that means I cant get around this. I cant even find a server with php 5.3 on to test on as its so out of date now!

    Thanks for the information its very helpful. i will have to find another way around this. Is it possible that you can send me some screenshots of the errors you get when trying to upgrade?

    All the best

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Hi there,

    I finally found a PHP 5.3 server I had from years ago to test on!

    Can you try editing the main base responsive-menu.php file and add this line below the responsive_menu_deactivation_text function – it needs to go around line 28:

    if(version_compare(PHP_VERSION, ‘5.4’, ‘<‘))
    return;

    If that stops the internal server and white screen errors then I will release it as a fix.

    Any questions let me know!

    Noticed the update.. just to let you know the message comes up even if I am running a higher level of PHP. 5.6 etc.

    “Responsive Menu requires PHP 5.4 or higher to function and has therefore been automatically disabled. You are still on 5.3.5.
    Please speak to your webhost about upgrading your PHP version. For more information please visit this page.”

    I know all this is maddening. I will probably just go ahead and by the Pro. I know the technology works great in general ??

    thanks

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Hey there,

    You dont have PHP 5.6, even the message tells you that you have PHP 5.3.5 installed.

    You will need to upgrade your PHP Im afraid to use it.

    All the best

    Oh no!!! Is there anyway I can have a previous version?!! I updated yesterday without seeing this…

    I just need it temporarily – my client wants to move their site over to a completely new server which is already running latest apache but it won’t be for about a month! Really need this working if pos…

    Plugin Contributor responsivemenu

    (@responsivemenu)

    Sure, you can get it from the Developers tab on the WordPress plugin main page.

    You need version 2.8.9

Viewing 15 replies - 1 through 15 (of 23 total)
  • The topic ‘Parse error: syntax error, unexpected T_FUNCTION in …’ is closed to new replies.