shaft Posted July 16, 2015 Share Posted July 16, 2015 Hello, I have a write script for xml import product from supplier and work fine under 1.6.0.x version with class. I wanted to use a script for this new version 1.6.1.0 and now I get this error "Fatal error: Class 'Context' not found in /srv/www/example.com/public/www/init.php on line 21. This is sample of script code: $presto_init = array("ObjectModel", "webservice/WebserviceRequest", "Tools", "shop/Shop", "db/Db", "db/DbPDO", "Context", "Configuration"); require_once('config/alias.php'); require_once('config/defines.inc.php'); require_once('config/settings.inc.php'); include('init.php'); ini_set('display_errors', 'on'); error_reporting(E_ALL | E_STRICT); class Worker { public static function loadPrestaShopClass($path) { require_once("classes/".$path.".php"); $file = explode("/", $path); $class = end($file); class_alias($class."Core", $class); return $class; } } Does anyone know, what Prestashop change in this version and how to change it to work? Thank you for your reply. Regards Shaft Link to comment Share on other sites More sharing options...
softhightech Posted March 14, 2017 Share Posted March 14, 2017 Check my answer here : https://www.prestashop.com/forums/topic/309082-fatal-error-class-context-not-found/ Link to comment Share on other sites More sharing options...
Recommended Posts