• Resolved nargonne

    (@nargonne)


    Getting Internal Server Error 500. Also PHP error is

    Parse error: syntax error, unexpected ‘)’ in ../scroll-triggered-boxes/src/BoxLoader.php(124) : eval()’d code on line 1

    The code that is causing problems is:

    $matched = eval( "return (" . $value . ");" );

    Changing it to the following appears to work:

    $matched = eval( "return " . $value . ";" );

    I think the issue is that php return is not a function so the parenthesis are unnecessary.

    https://www.ads-software.com/plugins/scroll-triggered-boxes/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Harish Chouhan

    (@hchouhan)

    Hello nargonne,

    Can you please confirm if you are using the latest version of our plugin?

    Thread Starter nargonne

    (@nargonne)

    Hi,

    Yes, version 2.1.1. I just now downloaded the plugin to check.

    It’s in scroll-triggered-boxes/src/BoxLoader.php on line number 124

    Plugin Author Danny van Kooten

    (@dvankooten)

    Hey Nargonne,

    Can you please take a look at your box configuration and look at what the value of your “manual condition” field is?

    Thanks!

    Thread Starter nargonne

    (@nargonne)

    Hi,

    The “Manual condition” field is blank. There is a field but it has no value; Only the placeholder text.

    Interestingly now that I am looking at this I see the “manual condition” isn’t needed although a blank field is there awaiting input.

    I clicked the X next to the field deleting it. Updated and reloaded the pages and the problem error is gone.

    I don’t know if the field was always there or if someone may have thought to add one and didn’t put in a value.

    I’m guessing this is close to resolved. I think it is best if the plugin can account for empty value here just to be sure.

    Plugin Author Harish Chouhan

    (@hchouhan)

    Hello Nargonne,

    I’m glad the issue is resolved and thank you for the suggestion. We will definitely consider it as it does make sense and would prevent accidental errors.

    Plugin Author Danny van Kooten

    (@dvankooten)

    Hey Nargonne,

    We pushed out an update of the plugin yesterday that takes empty values into account – very nice find! Thank you!

    PS: If you a have a few seconds, a plugin review would make us very happy!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Syntax Error from BoxLoader.php’ is closed to new replies.