We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 1628
    • 17 Posts
    Is there a system setting or other method (outside of a plugin) that will clear the error log after a certain amount of time or certain file size?
      • 6228
      • 249 Posts
      I’m sure it would be easy to write a plugin that fires the processor that clears the log on a specific event.

      But why, pray tell, would you want to do that?
        lo9on.com

        MODx Evolution/Revolution | Remote Desktop Training | Development
        • 3749
        • 24,544 Posts
        It’s usually better to figure out where the errors are coming from and fix them. wink
          Did I help you? Buy me a beer
          Get my Book: MODX:The Official Guide
          MODX info for everyone: http://bobsguides.com/modx.html
          My MODX Extras
          Bob's Guides is now hosted at A2 MODX Hosting
          • 1628
          • 17 Posts
          I have corrected all errors generated from our custom code, though some errors are user generated, such as attempting to create a new resource with the same alias as an existing resource. I just thought that the Modx error log would have similar functionality to a server error log, giving me the option of only keeping XX numbers of days worth of log before replacing those records and clearing the log all together. I could write a plug-in, though that feels like the wrong way to go about it.
            • 28042 ☆ A M B ☆
            • 24,524 Posts
            Writing a plugin is exactly the way to go about adding any custom functionality to the MODx core. That’s what plugins are for.
              Studying MODX in the desert - http://sottwell.com
              Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
              Join the Slack Community - http://modx.org