This problem came out of my interest in a category replacement that wouldn't work for me. As soon as the Auto_Loader was added, all I'd receive was a blank page.
1. I have turned on logging, display_startup errors, display errors.
2. I've added enable_error_logging.php file to the /includes/extra_configures/ folder.
3. I have also done the following in /includes/local/configure.php
PHP Code:
<?php
ini_set('display_errors', '1');
//define('STRICT_ERROR_REPORTING', true);
error_reporting(E_ALL | E_STRICT);
?>
Now for the code, the Auto_Loader is
PHP Code:
<?php
/**
* ch_categories_tree_generator
* @Version:
* @Authour:
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
*/
//if (!defined('IS_ADMIN_FLAG')) {
// die('Illegal Access');
//}
$autoLoadConfig[100][] = array('autoType'=>'class', 'loadFile'=> 'simple_categories_generator.php');
$autoLoadConfig[100][] = array('autoType'=>'classInstantiate',
'className'=>'simple_categories_gen',
'objectName'=>'cat_gen');
// 'checkInstantiated'=>true,
// 'classSession'=>true);
//$autoLoadConfig[200][] = array('autoType'=>'objectMethod',
// 'objectName'=>'cat_tree',
// 'methodName' => 'init');
?>
And the complex and fancy class is (aka stub)
PHP Code:
<?php
/**
* Simple Category Tree
* @Version: Beta 1
* @Authour: yellow1912
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
*/
class simple_categories_gen extends base {
function simple_categories_gen() {die("help");}
function init(){ die("me"); }
}
?>
now it used to actually have code, but I cut it all out in an attempt to find the problem. I've added Die("here") to the class file and that worked... but adding die("here") IN the class methods doesn't actually get executed.
Now yellow1912 and I have spent a lot of time on this and have hit a brick wall. So I really need some new ideas and feedback please.
Bookmarks