Zen Cart Logo
Forums / General Questions / myDEBUG log files in cache folder

myDEBUG log files in cache folder

Views: 2,700

Results 1 to 3 of 3
26 Jun 2011, 7:27 AM
#1
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

myDEBUG log files in cache folder

Good day,

Could somebody please explain why log files named myDEBUG-999999-999999.log keep accumulating in my cache folder? Their content is:

[17-Jun-2011 18:16:21] PHP Fatal error: Call to a member function buildTree() on a non-object in /home3/MYUSER_ID/public_html/includes/templates/MY_TEMPLATE/templates/tpl_page_not_found_default.php on line 27

(bolded blue characters masking real names)

Line 27 referred in the error message is:

<div><?php echo $zen_SiteMapTree->buildTree(); ?>

My Zen Cart version is 1.3.9h and the URL is Athens Collectibles if that helps.

Any assistance will be much appreciated. Many thanks in advance.

26 Jun 2011, 7:42 AM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: myDEBUG log files in cache folder

Those files are generated anytime a PHP error occurs in your ZC files. Evidently something's not working correctly when your custom page-not-found template is loaded.

26 Jun 2011, 10:04 AM
#3
athens_collectibles avatar

athens_collectibles

Zen Follower

Join Date:
May 2010
Location:
Athens, Greece
Posts:
293
Plugin Contributions:
0

Re: myDEBUG log files in cache folder

Thank you DrByte, I really appreciate the very prompt reply :D

I had read previous postings about these files before starting this thread. I was actually hoping to get some guidance on where to look for correcting this error.

Being an old stubborn donkey and not accepting defeat, I played around and came to a solution which seems to work: I deleted everything from line 27 to the end of the file and here is what it's left of it:

<?php
/**
 * Page Template
 *
 * Displays page-not-found message and site-map (if configured)
 *
 * @package templateSystem
 * @copyright Copyright 2003-2005 Zen Cart Development Team
 * @copyright Portions Copyright 2003 osCommerce
 * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
 * @version $Id: tpl_page_not_found_default.php 3230 2006-03-20 23:21:29Z drbyte $
 */
?>
<div class="centerColumn" id="pageNotFound">
<h1 id="pageNotFoundHeading"><?php echo HEADING_TITLE; ?></h1>

<?php if (DEFINE_PAGE_NOT_FOUND_STATUS == '1') { ?>
<div id="pageNotFoundMainContent" class="content">
<?php
/**
 * require the html_define for the page_not_found page
 */
  require($define_page); ?>
</div>
<?php } ?>

I repeatedly triggered my custom "Page not found" in English and Greek and it is rendered correctly without log files being produced. I'm quite happy now.

I know that it's not correct to change core files, but I keep a list of those I have edited and will find my way around when there is a new release.

Just a last question please: some php files have an intended blank line at the end. I don't know the reason, but should I insert a blank line at the end of the tpl_page_not_found_default.php after my changes?

Thanks again and have a nice day. :smile: