PHP Snippet to Delete Logs After X Days
-
Hi there,
As most of you know, the plugin’s “Clear Logs” button is gone. There’s a good plugin out there that can clear the logs, but it still requires “manual action.”
To all you devs or gurus out there, do you know of a snippet (PHP Code) that can automatically delete the logs after X number of days? If so, please share.
I assume two things would be needed here:
(1) A snippet (PHP code) that deletes the affected database (“wp_***_itsec_logs) files.
(2) A cron job that would execute the snippet every x number of days.
Cheers!
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘PHP Snippet to Delete Logs After X Days’ is closed to new replies.