Support

Akeeba Backup for Joomla!

#8429 Parse error

Posted in ‘Akeeba Backup for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Akeeba Backup version
n/a

Latest post by nicholas on Saturday, 04 June 2011 11:52 CDT

user10337
I keep getting the following error on my cron backup: "Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/user/site.com/administrator/components/com_akeeba/akeeba/factory.php on line 33

Any ideas??

PHP 5.2.13
Joomla 1.5.15

user10337

dlb
That error indicates that your php version is too old. It should not happen with php 5.2.13. Please double check your php version on your Joomla! installation, on the back end, under the help menu item. That will tell you what version of php Joomla! thinks you're running. Many hosts offer more than one version of php, the versions can be switched in the .htaccess file, for example.


Dale L. Brackin
Support Specialist


us.gifEnglish: native


Please keep in mind my timezone and cultural differences when reading my replies. Thank you!


????
My time zone is EST (UTC -5) (click here to see my current time in Philadelphia, PA)

user10337
That was my first thought too but I checked and PHP version is correct. Any other ideas?

dlb
Yep, same idea I always have when I run out of ideas. :) I'll ask Nicholas.


Dale L. Brackin
Support Specialist


us.gifEnglish: native


Please keep in mind my timezone and cultural differences when reading my replies. Thank you!


????
My time zone is EST (UTC -5) (click here to see my current time in Philadelphia, PA)

nicholas
Akeeba Staff
Manager
The only way to get this error is a PHP version mismatch. I've checked on a local host with PHP 5.2.13 and 5.2.4 (since I couldn't read the image very clear, I tested both) and Akeeba Backup works. Most probably your host assigns the PHP version using special .htaccess directives. In this case, it is possible that scripts on one page use PHP 5 and scripts on another page use PHP 4. You should file a support ticket with your host asking them the necessary steps to enable PHP 5 throughout your site.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user10337
I can run backups no problem. It is only when trying to run and automated backup from a cron job that causes the error.

Just sent you message to my host to see what they say about PHP on their back end.

nicholas
Akeeba Staff
Manager
That explains it all! The command-line version of PHP is not always the same as the one used in the web server. Some hosts have a PHP4 binary named "php" and a PHP5 binary named "php5". Your host's support should point you to the correct one.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user10337
That did it. Host let me know that they use usr/local/bin/php to point to the PHP4 binary and usr/local/php5/bin/php for PHP5. Adding that solved the problem. Thanks!

nicholas
Akeeba Staff
Manager
You're welcome :)

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user11859
Just a quick note to let you know that the answer to this post helped me too :).

nicholas
Akeeba Staff
Manager
You're welcome :)

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!