0

I updated Craft to version 2.6.2798.

Since then I'm getting a PHP error:

Parse error: syntax error, unexpected '[' in /craft/app/fieldtypes/BaseElementFieldType.php on line 428

PHP version on the server is 5.53.

Any ideas to fix that issue?

  • 1
    "PHP version on the server is 5.53." You sure about that? That error is a bug in Craft (just fixed for the next release) that indicates you're probably running PHP 5.3.x. – Brad Bell Jul 28 '16 at 05:27

2 Answers2

3

This has been fixed in Craft 2.6.2804.

Brandon Kelly
  • 34,307
  • 2
  • 71
  • 137
1

I got exactly the same issue, not sure what PHP version i'm on though. It is possible to access the login screen, but after getting redirected to the dashboard it shows a HTTP 500 error message and with 'devmode on' it gives me this same error on whatever page off my site I try to access.

EDIT: Ok, this may be a bit of a radical solution, but I just deleted the following on line 428 in the file:

    'criteria' => [
        'locale' => $targetLocale
    ],

At least everything is working again... But a more substantiated solution would be nice ;)

Pim S.
  • 11
  • 2
  • Looks like some PHP 5.4 syntax got into the release. We’ll get an update out ASAP that fixes this. Deleting these lines works, or changing [ to array( and ] to ). – Brandon Kelly Jul 28 '16 at 12:22