Framework: Laravel 5.5 - Syntax error

Created on 22 Jan 2018  路  10Comments  路  Source: laravel/framework

  • Laravel Version: 5.5.32
  • PHP Version: 7.0
  • Database Driver & Version:

Description:

After running composer update command, following error occurred:
PHP Parse error: syntax error, unexpected '?' in /home/apps/auditus/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php on line 233

Following the file and error line:
Helpers.php:

        if (is_string($arguments[0])) {
                return app('cache')->get($arguments[0], $arguments[1] ?? null);
        }

Steps To Reproduce:

Most helpful comment

are you sure your running PHP7? That error looks like your not...?

All 10 comments

are you sure your running PHP7? That error looks like your not...?

I runned phpinfo(); and it shows me this: PHP Version 7.0.26

Sounds like something's gone wrong in your vendor folder to me. Just delete vendor and then do composer install.

Are you sure that the CLI version of PHP is also 7.0? Run php -v to see this.

Nope, introduced in PHP 7.0.

im getting same issue in web hosting

please help me

@BookNetwork Are you on PHP 7.0+?

im getting same issue in web hosting

I think that you should update your php version.

Even I am also. These issues in local system anyone could help me out

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lzp819739483 picture lzp819739483  路  3Comments

klimentLambevski picture klimentLambevski  路  3Comments

Anahkiasen picture Anahkiasen  路  3Comments

felixsanz picture felixsanz  路  3Comments

YannPl picture YannPl  路  3Comments