Zen Cart Logo
Forums / Addon Admin Tools / Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

Views: 22,771

Results 61 to 80 of 95
28 Dec 2014, 9:03 PM
#61
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

v1.0.9 is now available from the Plugins area. The update provides downwardly-compatible changes required for Zen Cart v1.5.4.

27 May 2016, 1:26 PM
#62
mesnitu avatar

mesnitu

Totally Zenned

Join Date:
Aug 2014
Location:
Lisbon
Posts:
597
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

Hi
This shop doesn't have SSL, so probably not advisable to add this plugin ?
However, I'm looking for something that sends a email to admin, if a log is generated... not sure if already exists.

I've realize that I had in version 151 , a lot, but a lot of log files, that I wasn't aware.
For me the way of "check your logs time to time" doesn't work.... or I get a notification... or I don't even remember what logs are.

This module does that ? Or it's more to just display on admin side the logs ?
Could it be done, to have this two options in this module ?
Example: if one has SSL, use this on admin, if not, just sends a email to the admins ?

Or something like just sending a email already exists ?
I think I can do this...probably... but I don't want to be reinventing the wheel ...

Thanks

“Though the problems of the world are increasingly complex, the solutions remain embarrassingly simple.” ― Bill Mollison

27 May 2016, 8:03 PM
#63
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

The aspect of not having a SSL and this plugin comes into effect at the point that the admin "page" for it is displayed where the contents of the files are pushed to the browser. That portion of the plugin could be omitted from the installation and the notification in the admin could remain (your "reminder" to check the files). The notification does include a link to the admin page (could be removed), but it also identifies the number of debug files which also could remain helpful.

As to the added feature of an email, well, that would be more of a "feature" to the original ZC code where if a notifier already exists, when a new file is generated that the email is sent. If it doesn't exist (haven't gone a looking) then one could be added to do the same. Whether that feature were incorporated into this plugin or not is somewhat a different issue.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

28 May 2016, 9:33 AM
#64
mesnitu avatar

mesnitu

Totally Zenned

Join Date:
Aug 2014
Location:
Lisbon
Posts:
597
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

mc12345678:

As to the added feature of an email, well, that would be more of a "feature" to the original ZC code

Yes, I see now, that my post doesn't make much sense. It must occur when zc generates the log and not when listing logs...
Got to find this thing, cause, as I said, for me, or I get some sort of notification, or bye bye.
And this couple of months that I've been reading logs and logs and logs.... I think I'll miss them. Don't want miss one.

Tanks.

“Though the problems of the world are increasingly complex, the solutions remain embarrassingly simple.” ― Bill Mollison

28 May 2016, 10:28 AM
#65
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

mesnitu:

Yes, I see now, that my post doesn't make much sense. It must occur when zc generates the log and not when listing logs...
Got to find this thing, cause, as I said, for me, or I get some sort of notification, or bye bye.
And this couple of months that I've been reading logs and logs and logs.... I think I'll miss them. Don't want miss one.

Tanks.

BTW, (and sorry for the slight off topic for this forum comment), hopefully you are not planning on emailing the error log with every time an error occurs. That can be worse than using this plugin without a SSL. Further, there really should be rare occurrences of errors.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

12 Jun 2016, 3:26 PM
#66
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

I've just submitted v2.0.0 to the Plugins for review. The plugin's log-file alert processing has been restructured so that there are no longer any core-file overwrites, enabling the plugin's use on all (current) Zen Cart versions in the 1.5.x series!

This version also includes a filter (so you can view only the myDEBUG*.log files) and additional sorts to enable sort-by file-size as well as creation-date.

If you are upgrading the plugin from a previous version, be sure to read the readme! It's got the instructions on removing that core-file modification from the v1.x.x series of Display Log Files.

21 Jun 2016, 11:54 AM
#67
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

v2.0.0 is now available for download.

10 Jun 2017, 6:40 PM
#68
ncrs_1962 avatar

ncrs_1962

New Zenner

Join Date:
Mar 2008
Posts:
12
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

I am using ZC Ver 1.5.3.

In the instructions for Display Log Files you indicate that I can choose to view only the log file I wish to view. I can't find any place to select that function. Am I missing something?

I am particularly interested in the PayPal log files.

11 Jun 2017, 12:55 PM
#69
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

@NCRS 1962, the current version of Display Logs allows you to view only the myDEBUG log files but that's as far as its filtering goes. I'll note your request (the ability to identify the "type" of logs to view) as a potential future change.

11 Jun 2017, 5:13 PM
#70
ncrs_1962 avatar

ncrs_1962

New Zenner

Join Date:
Mar 2008
Posts:
12
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

Thanks,

That would be helpful for me.

9 Jul 2017, 8:47 PM
#71
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

I've just submitted v2.1.0 of Display Log Files to the plugin section for review; I'll post back here when it's available.

That version:

  1. Corrects a programming error that resulted in the selected log-file's contents not displaying under PHP 7.1.x and later.
  2. Enhances the plugin, moving all configurable elements into your admin's Configuration->Logging, addressing the request from @NCRS 1962.
10 Jul 2017, 3:28 PM
#72
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

lat9:

I've just submitted v2.1.0 of Display Log Files to the plugin section for review; I'll post back here when it's available.

That version:

  1. Corrects a programming error that resulted in the selected log-file's contents not displaying under PHP 7.1.x and later.
  1. Enhances the plugin, moving all configurable elements into your admin's Configuration->Logging, addressing the request from @NCRS 1962.

I've updated the plugin to v2.1.1 (just submitted to the plugins); v2.1.0 mistakenly removed the file-sort functionality.

10 Jul 2017, 7:15 PM
#73
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

lat9:

I've just submitted v2.1.0 of Display Log Files to the plugin section for review; I'll post back here when it's available.

That version:

  1. Corrects a programming error that resulted in the selected log-file's contents not displaying under PHP 7.1.x and later.
  1. Enhances the plugin, moving all configurable elements into your admin's Configuration->Logging, addressing the request from @NCRS 1962.

lat9:

I've updated the plugin to v2.1.1 (just submitted to the plugins); v2.1.0 mistakenly removed the file-sort functionality.
v2.1.1 is now available for download from the Zen Cart Plugins area.

11 Jul 2017, 9:36 PM
#74
heathenmagic avatar

heathenmagic

Totally Zenned

Join Date:
May 2005
Location:
England
Posts:
733
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

This is a great module! Like how it has a notification at the top of admin.

I have an issue which is driving me crazy right now, well for quite a while it has been doing this since php 7 change.

It shows Paypal logs, but no other error log types for the last 6 months. But in June it showed one 'mydebug.....' log regarding whos online. And I know for certain it should have a whole heap of error logs.

Sorry to pose this question in this thread. I asked the server people and they say its not server settings, and Dr Byte kindly helped with some advice which they were not able to utilise to help pinpoint what it is.

The mod works great, I like how you can filter out the paypal logs also. Many thanks for this!

11 Jul 2017, 9:59 PM
#75
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

@HeathenMagic, the PayPal logs (and many of the other processing/trace type logs) are written using a different method than the myDEBUG*.log files. They're written as a "regular" file that happens to have a .log file-extension.

The myDEBUG*.log files are created using PHP's error-handling, as modified by the built-in Zen Cart /includes/extra_configures/enable_error_logging.php script. If you're not receiving these error-indicator logs, then there's something in your PHP configuration that's preventing them from being written to the /logs directory.

You can see your site's PHP error configuration using Tools->Server/Version Info; I've attached the settings for one of my "localhost/XAMPP" setups that contain the error-related settings that might be messed:

display_errors	Off	On
display_startup_errors	On	On
doc_root	no value	no value
docref_ext	no value	no value
docref_root	no value	no value
enable_dl	On	On
enable_post_data_reading	On	On
error_append_string	no value	no value
error_log	C:/xampp/htdocs/zc155e/logs/myDEBUG-adm-1499810033-259371.log	C:\xampp-5.6.15\php\logs\php_error_log
11 Jul 2017, 10:15 PM
#76
heathenmagic avatar

heathenmagic

Totally Zenned

Join Date:
May 2005
Location:
England
Posts:
733
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

lat9:

@HeathenMagic, the PayPal logs (and many of the other processing/trace type logs) are written using a different method than the myDEBUG*.log files. They're written as a "regular" file that happens to have a .log file-extension.

The myDEBUG*.log files are created using PHP's error-handling, as modified by the built-in Zen Cart /includes/extra_configures/enable_error_logging.php script. If you're not receiving these error-indicator logs, then there's something in your PHP configuration that's preventing them from being written to the /logs directory.

You can see your site's PHP error configuration using Tools->Server/Version Info; I've attached the settings for one of my "localhost/XAMPP" setups that contain the error-related settings that might be messed:

display_errors Off On
display_startup_errors On On
doc_root no value no value
docref_ext no value no value
docref_root no value no value
enable_dl On On
enable_post_data_reading On On
error_append_string no value no value
error_log C:/xampp/htdocs/zc155e/logs/myDEBUG-adm-1499810033-259371.log C:\xampp-5.6.15\php\logs\php_error_log


Many thanks for your reply and your help with this! I think comparing with your example, the error_log setting in my config looks suspect:-

> display_errors	Off	On
> display_startup_errors	On	On
> doc_root	/home/*****/public_html	/home/*****/public_html
> docref_ext	no value	no value
> docref_root	no value	no value
> enable_dl	On	On
> enable_post_data_reading	On	On
> error_append_string	no value	no value
> error_log	/home/*****/logs/******_com.php.error.log 	/home/*****logs/*******_com.php.error.log

I replaced sensitive words with *  as I think is advised. I will contact them to change 'error_log' setting, I can't find that directory it mentions. I think that must be the cause. Fingers crossed
12 Jul 2017, 12:51 PM
#77
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

HeathenMagic:

Many thanks for your reply and your help with this! I think comparing with your example, the error_log setting in my config looks suspect:-

I replaced sensitive words with * as I think is advised. I will contact them to change 'error_log' setting, I can't find that directory it mentions. I think that must be the cause. Fingers crossed
The "error_log" setting is changed to have a different file name (the numeric suffixes at the end of the log file name) on each page-load (both admin and storefront). Those values are set with the PHP*** ini_set*** function which is apparently disabled on your site. Check with your webhost and ask them to re-enable the use of that function.

12 Jul 2017, 2:07 PM
#78
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

lat9:

The "error_log" setting is changed to have a different file name (the numeric suffixes at the end of the log file name) on each page-load (both admin and storefront). Those values are set with the PHP*** ini_set*** function which is apparently disabled on your site. Check with your webhost and ask them to re-enable the use of that function.
When you're viewing your site's Server/Version Information, search for disable_functions; most likely ini_set is in that list. Ask your webhost what can be done to remove that restriction.

13 Jul 2017, 2:40 PM
#79
heathenmagic avatar

heathenmagic

Totally Zenned

Join Date:
May 2005
Location:
England
Posts:
733
Plugin Contributions:
0

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

Thanks again for your help with this. I contacted them but they said the following:-

The PHP function "ini_set" is not disable on your server. Please view the snippet below.

=========================
root@server [/home/gemtree/public_html]# grep disable_functions /opt/cpanel/ea-php70/root/etc/php.ini
disable_functions =
root@server [/home/gemtree/public_html]#

Though it contradicts what is set in php settings:-

disable_functions no value no value

I think it should say 'ini_set' as you mentioned.

13 Jul 2017, 2:56 PM
#80
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,102
Plugin Contributions:
56

Re: Display Log Files [Support Thread] (v1.5.1-to-v1.5.6)

Take the following contents, put them into a file named something.php in your store's root directory; then run https://www.yourstore.com/something.php.

It will let you know if the error-log file name was properly set.

<?php
require 'includes/application_top.php';
$current_error_log = ini_get('error_log');

echo "The current error-log file is $current_error_log.<br />";

if ($current_error_log != $debug_logfile_path) {
  echo "The current error log is not set correctly, it should be $debug_logfile_path; retrying ....<br />";
  ini_set('error_log', $debug_logfile_path);
  echo "Reset error_log to " . ini_get('error_log') . '<br />';
}

require 'includes/application_bottom.php';