Is there a build for Editor that works on PHP 5.3?
Is there a build for Editor that works on PHP 5.3?

Getting errors for Editor on square brackets on PHP 5.3.3. Is there a build for Editor that works on PHP 5.3?
This question has accepted answers - jump to:
This discussion has been closed.
Answers
Which line is causing the error please? The libraries should actually work with 5.3 (although I would suggest you upgrade really soon - PHP 5.3 hasn't been receiving security patches in a decade!).
We've also noticed some bugs in the earlier PHP 5.3 releases which were address in the latest patch releases. So even if you can't go to 5.4 (or better 7.x) I'd suggest updating to 5.3.29 which I think should resolve the issue.
Allan
Thanks Allan.
The current error is:
Parse error: syntax error, unexpected '[' in /var/www/html/curriculum_mapper/datatables/lib/Database.php on line 136
If I changed that, there would probably be other places which would need to be addressed. I have asked out IT people at UWA to put PHP 5.4 on dev to test.
That's this. I think that is actually meant to be valid PHP 5.3, but I've committed a change.
I'll see if there is a way we can run our tests on PHP 5.3.
Allan
Thanks for the change snippet, I'm not getting the error anymore. However, I have a new error:
```
<?php > ``` ?>require_once( 'connection/connect.php' );
mysql_select_db( $database, $connection );
include( "datatables/lib/DataTables.php" );
use DataTables\Editor;
$editor = Editor::inst( $db, 'user', 'user_pk' )->fields(
Field::inst( 'first_name' ), //line 7
Field::inst( 'last_name' ),
Field::inst( 'email' ),
Field::inst( 'username' ),
Field::inst( 'user_type' ),
Field::inst( 'created' ),
Field::inst( 'created_by' ),
Field::inst( 'updated' ),
Field::inst( 'updated_by' )
)
->process( $_POST )
->json();
You're lacking some "use" statements.
Look at the server script code here::
https://editor.datatables.net/examples/simple/simple.html
Thanks, got it working now.
Allan, your simple fix for the editor to work with 5.3 works just fine.