I have a script that uses a PHP 5 syntax that's apparently not supported in PHP 4.
like MyClass::method()->method(...)
I'm trying to display a error at the beginning of the script telling that the server doesn't have PHP 5 installed, and "die" nicely, but I can't because I get that stupid parse error...
So how can I make PHP ignore errors if < 5 ?
PHP_VERSIONconstant though and write a nicer error message. But not in the same script, you have to test it before the potentially failing code gets invoked.