CubeCart v3 and PHP 5.3.x: Difference between revisions
Docs admin (talk | contribs) No edit summary |
Docs admin (talk | contribs) No edit summary |
||
Line 15: | Line 15: | ||
and change: | and change: | ||
< | <highlightsyntax lang="php"> | ||
error_reporting(E_ALL ^ E_NOTICE); | error_reporting(E_ALL ^ E_NOTICE); | ||
</ | </highlightsyntax> | ||
to: | to: |
Revision as of 17:51, 4 October 2012
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:
<highlightsyntax lang="php"> error_reporting(E_ALL ^ E_NOTICE); </highlightsyntax>
to:
<syntaxhighlight lang="php"> error_reporting(E_ALL and ~(E_NOTICE | E_STRICT | E_DEPRECATED | E_USER_DEPRECATED)); <syntaxhighlight>
It is also suggested to update the file:
admin/filemanager/upload.php
and add the line:
<syntaxhighlight lang="php">
include("../../includes/ini.inc.php");
below this line:
<syntaxhighlight lang="php"> // Init var : </syntax>
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.