Parse error when activating sage-master theme

Parse error: syntax error, unexpected ‘[’ in /home/wwwheads/public_html/mandm/wp-content/themes/sage-master/functions.php on line 12

This is what I see after activating sage starter theme. Can anyone point me to a solution for this? Thanks a lot

Your environment doesn’t support the short syntax for arrays, so you will need to upgrade php to 5.4 or above.

1 Like

I’ve just posted another topic before seeing this, and I get the above error as well and I have updated php to be 5.5.21 and the problem still persists. Is there something specifically that needs to be enabled in php?

You don’t mention anything about your setup.

Use phpinfo(); to double check that your updated php is running. You may need restart services before the update takes effect.

If that doesn’t work we’ll need some more to go on.

I thought i had checked this before, but it says, so yes, its a php version issue. My apologies!


I’m experiencing this same error. I updated PHP, restarted apache, and even made sure short_open_tag was turned on (per someone else’s suggestion)…but I’m still getting this error–albeit it’s no longer giving me the PHP error box and instead the error is just in text. (Not sure why the change.) The version of PHP I’m running is 5.4.27. Any thoughts?

What’s the actual error? If it’s unexpected '[' then 5.4 is not being used. Also, short_open_tag is always on in PHP 5.4, so you shouldn’t need to enable it.