[program-l] Re: Weird/strange issue with PHP file

  • From: "Jacob Kruger" <jacob@xxxxxxxxxxxxx>
  • To: <program-l@xxxxxxxxxxxxx>
  • Date: Wed, 10 Oct 2012 08:19:02 +0200

Ok, testing it on various hosting packages/software on windows7 64 bit machine now brings up following reactions.


On XAMPP, which tells me the following from phpinfo():
PHP Version 5.3.8

This line:
$iIndex = array_flip($this->arPlayers)[$sPlayer];

Returns/brings up the following error message:
Parse error: syntax error, unexpected '['

But, if I split it over 2 lines again, then it works fine...

Then, using verrtrigoserv:
PHP Version 5.3.10

Same error:
Parse error: syntax error, unexpected '['

But, split into 2 lines works fine there as well.

And, referring to my primarily used WAMP package/server:
PHP Version 5.4.3

It's still quite happy with either version.

For referral, the live hosting server returns the following version info:
PHP Version 5.2.17

Bit weird, and still not sure why live server just sort of hangs up instead of telling me about an error occuring - will see if can make any changes there somehow, or maybe it's best to leave it 'clean', and possibly just implement a bit more of my own error handling for pages going 'live' or something.

Alternatively, might try roll back WAMP to slightly earlier version, or maybe at the very least, test/try out things on XAMPP instance before putting them up on live server.

Stay well

Jacob Kruger
Blind Biker
Skype: BlindZA
'...fate had broken his body, but not his spirit...'

----- Original Message ----- From: "Jacob Kruger" <jacob@xxxxxxxxxxxxx>
To: <program-l@xxxxxxxxxxxxx>
Sent: Tuesday, October 09, 2012 11:51 PM
Subject: [program-l] Re: Weird/strange issue with PHP file


Will maybe test the other server versions have got here on this machine as well - don't know all versions, but have got couple of instances of XAMPP (portable), WAMP, and something called vertrigoserve, and they're pretty much all configurations/packages similar to WAMP, etc.

Stay well

Jacob Kruger
Blind Biker
Skype: BlindZA
'...fate had broken his body, but not his spirit...'

----- Original Message ----- From: "QuentinC" <webmaster@xxxxxxxxxxxx>
To: <program-l@xxxxxxxxxxxxx>
Sent: Tuesday, October 09, 2012 10:55 PM
Subject: [program-l] Re: Weird/strange issue with PHP file


Php 5.2.x vs 5.4. OK, so I would really advice to download a WAMP package so that you have the same version or allmost the same as the one you have on your production server. There are a lot of tricky differences between 5.2 and 5.3. For example, one of them screwed up all my ini-style files I was used to read with parse_ini_file. I know that some adjustments have been made to syntax, not only to allow anonymous functions and additionnal magic members. I don't know for 5.4 because I don't have it myself but I'm sure the key is there.
** To leave the list, click on the immediately-following link:-
** [mailto:program-l-request@xxxxxxxxxxxxx?subject=unsubscribe]
** If this link doesn't work then send a message to:
** program-l-request@xxxxxxxxxxxxx
** and in the Subject line type
** unsubscribe
** For other list commands such as vacation mode, click on the
** immediately-following link:-
** [mailto:program-l-request@xxxxxxxxxxxxx?subject=faq]
** or send a message, to
** program-l-request@xxxxxxxxxxxxx with the Subject:- faq


** To leave the list, click on the immediately-following link:-
** [mailto:program-l-request@xxxxxxxxxxxxx?subject=unsubscribe]
** If this link doesn't work then send a message to:
** program-l-request@xxxxxxxxxxxxx
** and in the Subject line type
** unsubscribe
** For other list commands such as vacation mode, click on the
** immediately-following link:-
** [mailto:program-l-request@xxxxxxxxxxxxx?subject=faq]
** or send a message, to
** program-l-request@xxxxxxxxxxxxx with the Subject:- faq


** To leave the list, click on the immediately-following link:-
** [mailto:program-l-request@xxxxxxxxxxxxx?subject=unsubscribe]
** If this link doesn't work then send a message to:
** program-l-request@xxxxxxxxxxxxx
** and in the Subject line type
** unsubscribe
** For other list commands such as vacation mode, click on the
** immediately-following link:-
** [mailto:program-l-request@xxxxxxxxxxxxx?subject=faq]
** or send a message, to
** program-l-request@xxxxxxxxxxxxx with the Subject:- faq

Other related posts: