The problem is with VisitMaisonInvestisseur::class
. class
is a reserved word in PHP, so you can't use it as the name of a constant.
If it works on your local server, it must be version-specific. But I've tested this in 5.3 and 5.6, and they both report an error for Classname::class
.