Akelos Framework v1 forum archive. This forum is no longer maintained. To report bugs please visit https://github.com/akelos/akelos/issues
    •  
      CommentAuthorjulio montoya
     
    How can I clean the content of the /tmp directory?

    I tried with
    $Cache = Ak::cache();
    $Cache->clean();
    But I got an error: Fatal error: Call to a member function clean() on a non-object

    I also tried this:

    include_once(AK_LIB_DIR.'/AkCache.php');
    $Cache = new AkCache();
    $Cache->clean();

    I guess I should use something like rm -r /tmp/ ???
    I have this setting also on: define ('AK_CACHE_HANDLER', 1); in a

    I'm in a production mode with Akelos trunk SVN#1440

    In fact I'm trying to refresh the /locales files after some changes.
    •  
      CommentAuthorbermi
     

    Hi Julio,

    clean should be handled properly by Cache_Lite when using the file based cache adapter if permissions are correct.

    $Cache = new AkCache();
    $Cache->clean(); // or $Cache->DriverInstance->clean();
    

    if there are permission problems running rm directly will give better information.

    $cmd = "rm -rf ".AK_CACHE_DIR;
    echo `$cmd`;