Forums / Developer / econtentobject.php

econtentobject.php

Author Message

Martin Jerie

Monday 23 October 2006 3:10:34 am

In my import script (run from shell) i have

     include_once( 'kernel/classes/ezcontentobjecttreenode.php' );

but when i run it i see error:

Parse error: syntax error, unexpected T_CLONE, expecting T_STRING in /var/www/vhosts/ezpublish/kernel/classes/ezcontentobject.php on line 1280

I use 3.8.4 and PHP 4.4.2

Nabil Alimi

Monday 23 October 2006 3:56:02 am

Hi Martin,

Can you show us the part of your code that uses the eZcontentobject class ?

My blog : http://www.starnab.com/ezpublish / http://www.starnab.com/ / http://www.assiki-consulting.com
eZ Publish Freelance developper. Feel free to contact me +33 674 367 057
nabil at assiki d0t fr

Martin Jerie

Monday 23 October 2006 4:46:15 am

It's in start of my script:

#!/usr/bin/php
<?php
set_time_limit( 0 );

// Include required files
include_once( "lib/ezutils/classes/ezextension.php" );
include_once( "lib/ezutils/classes/ezmodule.php" );
include_once( 'lib/ezutils/classes/ezcli.php' );
include_once( 'kernel/classes/ezscript.php' );
include_once( 'lib/ezutils/classes/ezexecution.php' );
include_once( 'kernel/classes/ezcontentobjecttreenode.php' );
include_once( 'kernel/classes/eznodeassignment.php' );
include_once( "lib/ezxml/classes/ezxml.php" );
include_once( "lib/ezxml/classes/ezdomdocument.php" );
include_once( "lib/ezxml/classes/ezdomnode.php" );
include_once( "kernel/classes/datatypes/ezxmltext/ezxmltexttype.php");
include_once( "kernel/classes/datatypes/ezxmltext/ezxmltext.php");

problem is in including ezcontentobjecttreenode.php, because it includes econtentobject.php and there i see this error

So i tried only this one row:

<?php
set_time_limit( 0 );
include_once( 'kernel/classes/ezcontentobject.php' );
?>

with same result

Kristof Coomans

Monday 23 October 2006 5:27:25 am

Hi Martin

I think you are using PHP 5 instead of PHP 4.4, right?

eZ does not officialy support PHP 5. Stick to PHP 4.4, or try the unofficial port to PHP 5: http://ez.no/community/forum/developer/ez_publish_3_x_on_php_5

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Martin Jerie

Monday 23 October 2006 5:38:52 am

No I'm using PHP 4.4.2 on Ubuntu Linux (6.06 LTS, the Ubuntu Server Edition)

Kristof Coomans

Monday 23 October 2006 6:03:10 am

Are you sure about that? Check with

# /usr/bin/php -v

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Martin Jerie

Monday 23 October 2006 6:13:31 am

You are right - PHP 5.1.2.
I will change to 4.4.2

Thank you Kristof

cas dav

Sunday 04 November 2007 3:29:02 am

#/usr/bin/php -v
PHP 5.2.4_p20070914-pl2-gentoo

#php-select php php4

#/usr/bin/php -v
PHP 4.4.8_pre20070816-pl0-gentoo