Iโm optimizing my site a bit. Tested the page locally, everything is in order. When I download it and access it live, it smoothly throws a parsing error ... but it works fine locally, as I said.
Parse error: syntax error, unexpected '[', expecting ',' or ';' in /home/theriff/www/frvideos.php on line 25
The code is as follows:
echo explode('|',$youtube[$i])[2].'<br />'."\r\n";
$ youtube [$ i] is a string formed as follows:
DFHG-LINKYOUTUBE-HJGHJ|french Description|English Description
The YouTube link is an identifier, so there is no '|' the symbol in it is for sure, and it is read from a text file that I write manually myself, so I'm sure of the record.
Does anyone know why it works fine on the local (EasyPhp Developper), but not on the remote server?
source share