webalizer cron_daily bug

Discussion in 'Developers' Forum' started by mghens, Jan 9, 2009.

  1. mghens

    mghens New Member

    I was wondering why my sites were not getting stats. Problem is that my weblogs are in the form of

    mdY

    01012009-access.log 01052009-access.log 12282008-access.log error.log
    01022009-access.log 01062009-access.log 12292008-access.log
    01032009-access.log 01072009-access.log 12312008-access.log
    01042009-access.log 01082009-access.log access.log

    but

    cron_daily.php is looking for: Ymd

    $yesterday = date("Ymd",time() - 86400);

    From man vlogger


    -t TEMPLATE
    Filename template using Date::Format codes. Default is "%m%d%Y-access.log",
    or "%m%d%Y-error.log". When using the -r option, the default becomes
    "%m%d%Y-%T-access.log" or "%m%d%Y-%T-error.log".


    Michael
     
  2. mghens

    mghens New Member

    Fix for me was to change:

    $yesterday = date("Ymd",time() - 86400);


    to

    $yesterday = date("mdY",time() - 86400);
     

Share This Page