PHP-Web-Stat Support Forum
https://www.php-web-statistik.de/cgi-bin/yabb/YaBB.pl
Board (English) >> English board >> Exclude phpWebStat from getting logged?
https://www.php-web-statistik.de/cgi-bin/yabb/YaBB.pl?num=1676604384

Beitrag begonnen von John Motyer am 17.02.23 um 04:26:24

Titel: Exclude phpWebStat from getting logged?
Beitrag von John Motyer am 17.02.23 um 04:26:24
Hello, Reimar & Holger.

I have my local (internal) IP set for exclusion in Admin Center | Advanced Settings, and this works great.  However, if you go HERE and then open up Last Hits, notice that phpWebStat is logging everything that phpWebStat is doing in the background.

In addition to phpWebStat logging visitors accessing other areas of my websites, I also wish for visitors to be logged when they access the main phpWebStat page (i.e. webstats/index.php), which it is doing OK, it's just all the other phpWebStat back-end that I do not wish to log.  My script to pws.php is located in func/html_footer.php

How can I have it, so that the only logging of phpWebStat is for when users access the phpWebStat main page  (example: webstats/index.php)?

Would it be OK for me to call pws.php from index.php only, and remove the call to pws.php from func/html_footer.php?  If it is possible for me to do it this way, where exactly in index.php should I place the call to the pws.php script code?

Thank you in advance, and have yourselves a great day.

Tschüß,
John

Titel: Re: Exclude phpWebStat from getting logged?
Beitrag von Reimar am 18.02.23 um 20:11:59
Hi John,

the footer file will be used for every html output, that's why you get logs for every little backend task. It would be indeed a much better idea to place it at the end of the index.php, as follows


Code (php):
...

#place it here without the the leading brackets:
include ( 'stat/config/tracking_code.php' );

include (html_footer)

?>


So it's needed to be placed just before the html footer is included.

Titel: Re: Exclude phpWebStat from getting logged?
Beitrag von John Motyer am 19.02.23 um 03:30:53
Thank you, that fixed the problem.

Much appreciated for getting back to me.

Have yourself a great day.

Regards,
John

PHP-Web-Stat Support Forum » Powered by YaBB 2.5.2!
YaBB Forum Software © 2000-2012. Alle Rechte vorbehalten.