syntax error, unexpected token “*”¶
Description¶
PHP accepts one star *
, for multiplication and two stars **
, for power, since PHP 7.0. More stars are not supported as operator.
Example¶
<?php
// star cannot be used directly after a +
$a = 2 + * 3;
// No such operator as 3 stars
$a = 2 *** 3;
?>
Solutions¶
Remove the previous operator, before the star.
Finish the previous operation, before the star.
Remove the superfluous star.