CubeCart v3 and PHP 5.3.x

From Acenet Knowledgebase
Revision as of 14:34, 28 September 2012 by Docs admin (Talk | contribs) (test)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

CubeCart v3.0.17 is the latest version available through Fantastico. After this version, CubeCart became a pay product and is no longer freely available.

PHP 5.3.x compatibility updates for CubeCart are only available in later versions of CubeCart than what is freely available via Fantastico. When CubeCart is run on PHP 5.3.x, you may notice the following errors:

Deprecated: Function eregi() is deprecated in ...

This solution is taken from the CubeCart forums here:

http://forums.cubecart.com/topic/39139-installation-on-thumbdrive-problem/page__p__166757

To address this problem, edit the file:

includes/ini.inc.php

and change:

error_reporting(E_ALL ^ E_NOTICE);

to:

error_reporting(E_ALL and ~(E_NOTICE | E_STRICT | E_DEPRECATED | E_USER_DEPRECATED));

It is also suggested to update the file:

admin/filemanager/upload.php

and add the line:

include("../../includes/ini.inc.php");

below this line:

// Init var :

This will disable warnings regarding deprecated functions. The E_DEPRECATED flag only provides warnings regarding features that will not work in the future. The eregi() function still operates correctly, but will not be supported in a future version of PHP. At this time, it is important to begin considering migrating to another shopping cart solution or upgrade to the pay version of CubeCart. Once the eregi() function is removed from a future version of PHP, CubeCart v3 will no longer function correctly.