Reputation: 359
I had built my website using Laravel 4, and it works fine on localhost but when I host it in my online webserver I've got this error:
Parse error: syntax error, unexpected T_USE, expecting T_FUNCTION in /home/.../public_html/bootstrap/compiled.php on line 3242
How can I get rid of this error?
Upvotes: 0
Views: 444
Reputation: 29433
Laravel 4.2 requires PHP 5.4+, make sure you have that.
If you updated from an earlier version of Laravel and on PHP 5.4+, remove public_html/bootstrap/compiled.php
and it should work again.
If you can't use 5.4+, use Laravel 4.1 instead of 4.2, so in your composer.json
you want "laravel/framework": "4.1.*",
instead of what you have now.
Upvotes: 2