Core: PHP parse error

Created on 9 Oct 2017  路  2Comments  路  Source: flarum/core

Explanation

Fresh install of Flarum following instructions on install page using composer. Installed as root user.


PHP Parse error: syntax error, unexpected 'finally' (T_STRING), expecting catch (T_CATCH) in .../vendor/flarum/core/src/Foundation/Application.php on line 132

Technical details

  • Version of Flarum: v0.1.0-beta.7
  • The webserver you are running: apache 2.4.6 on CentOS 7
  • PHP version: 7.0.23
  • Hosted environment: dedicated server

Flarum info

Output of "php flarum info", gives me:

[Symfony\Component\Console\Exception\CommandNotFoundException]  
  Command "info" is not defined.

Most helpful comment

That was it exactly. I forgot to restart apache after upgrading PHP.
Thank you. Flarum is looking great!

All 2 comments

Are you sure Flarum is being run with PHP 7? The finally keyword was introduced in PHP 5.5 so it would be odd to see this error on any version after that. Could it be that you've installed PHP 7 but Apache is still using PHP 5 for Flarum requests?

That was it exactly. I forgot to restart apache after upgrading PHP.
Thank you. Flarum is looking great!

Was this page helpful?
0 / 5 - 0 ratings