View Single Post
  #3  
Old 10-27-2013, 08:17 AM
 
gblair gblair is offline
 

Advanced Member
  
Join Date: Jul 2008
Posts: 69
 

Default Re: PHP 5.4 compatibility for older versions of X-Cart (4.0.19; 4.1.12)

I'm looking at applying the php 5.3 patches to our 4.1.10 x-cart.

All seems like it's going to work except:

func.compat.php not found - but I saw the work around for that in another thread.

init.php - could not patch - patch cannot be applied to this file automatically because it was significantly modified, the patch for this file should be applied manually,

I compare the script for both versions and it seems the only difference I can find is to add:

x_load('db','files', 'compat');

func_set_memory_limit("16M");

#
# Aloow displaying content in functions, registered in register_shutdown_function()
#
$zlib_oc = ini_get("zlib.output_compression");
if (!empty($zlib_oc) || func_version_compare(phpversion(), "4.0.6") <= 0)
define("NO_RSFUNCTION", true);

unset($zlib_oc);

if (func_version_compare(phpversion(), "5.3.0") >= 0) {
define('X_PHP530_COMPAT', true);
}

if (function_exists('date_default_timezone_get') && function_exists('date_default_timezone_set'))
@date_default_timezone_set(@date_default_timezone_ get());

if (!@is_readable($xcart_dir."/config.php")) {
echo "Can't read config!";
exit;
}


Before I go ahead and screw it up, can you confirm that's all I need to do?
__________________
paperwhimsy.com
Gale Blair
4.1.10
Reply With Quote