Aaron Smith Mon Nov 22 23:56:26 -0500 2010

Subject: PHP Minimum Version? Errors with ActiveRecord\Config

Is there a minimum version of PHP required to support activerecord?

Locally I'm using 5.3.3 and it works fine. But when I put it on my server with PHP 5.2.10 I get parse errors at the config line:

PHP Warning: Unexpected character in input: '\' (ASCII=92) state=1 in [FILE] on line 3
PHP Parse error: syntax error, unexpected T_STRING in [FILE] on line 3

Any ideas?
Thanks!


Chris R Tue Nov 23 11:22:00 -0500 2010

PHP-AR makes use of namespaces, which were introduced in PHP 5.3. It will not work on lower versions because the '\' character used to define namespaces is not recognised by the PHP parser.

http://php.net/manual/en/language.namespaces.rationale.php

Hope this helps,

Chris

Aaron Smith Tue Nov 23 17:44:59 -0500 2010

thanks that helps. just gotta upgrade php.

(1-2/2)