[1.8git] ClearCache Cronjob

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • [1.8git] ClearCache Cronjob

      Ich suche nach einer Möglichkeit den Cache automatisch via Cronjob leeren zu lassen. Gibt es da eventuell schon einen Mod oder eine class für?


      Iam looking for an solution to clear the chache automaticly over a Cronjob. Is there a Mod or an class-file for it?


      Danke für eure hilfe

      Thx for ure help
    • I do not think there is a task to do for that but you can easily create it
      I remain at your disposal on the forum for any questions or help.

      A help is of course not a creation of a mod



      -------------------------------------------------------
      Spaccon
      • Uni Xterium Comming Soon
      • Uni Ogame Comming Soon
    • Thx for ure help, maybe ive done it^^


      PHP Source Code

      1. <?php
      2. /**
      3. * 2Moons
      4. * by Jan-Otto Kröpke 2009-2016
      5. *
      6. * For the full copyright and license information, please view the LICENSE
      7. *
      8. * @package 2Moons
      9. * @author Jan-Otto Kröpke <slaver7@gmail.com>
      10. * @copyright 2009 Lucky
      11. * @copyright 2016 Jan-Otto Kröpke <slaver7@gmail.com>
      12. * @licence MIT
      13. * @version 1.8.0
      14. * @link https://github.com/jkroepke/2Moons
      15. */
      16. require_once 'includes/classes/cronjob/CronjobTask.interface.php';
      17. class ClearCacheCronjob implements CronjobTask
      18. {
      19. function run()
      20. {
      21. require 'includes/GeneralFunctions.php';
      22. $clear = new ClearCache();
      23. $clear->ClearCache();
      24. }
      25. }
      Display All
      But Cronjob is Locked in the Cronjobslist. How to fix this problem? Any Ideas or ive made some wrong?

      The post was edited 1 time, last by TheAlex ().

    • Iam think this is the Problem:

      Source Code

      1. $clear = new ClearCache();
      2. $clear->ClearCache()
      3. changed to
      4. ClearCache();
      5. //edit 2
      6. changed to
      7. require_once 'includes/GeneralFunctions.php';
      8. ClearCache();
      Display All

      The post was edited 1 time, last by TheAlex ().

    • Um es mal für alle zur verfügung zu stellen:


      Source Code

      1. require_once 'includes/classes/cronjob/CronjobTask.interface.php';
      2. class ClearCacheCronjob implements CronjobTask
      3. {
      4. function run()
      5. {
      6. require_once 'includes/GeneralFunctions.php';
      7. ClearCache();
      8. }
      9. }
      So läuft es unter 1.8Git problemfrei. Für jeden der es benötgen könnte.
      Files
      • clearcache.zip

        (1.17 kB, downloaded 24 times, last: )

      The post was edited 1 time, last by TheAlex ().