in reply to Checking file Mod date

perldoc -f "-X"

-- Hofmator

Replies are listed 'Best First'.
Re: Re: Checking file Mod date
by LostS (Friar) on Jul 19, 2001 at 17:34 UTC
    Does anyone have an example on how to use this function...
    Like what is the output? How will it display the last mod date??

      The -M filetest operator gives the number of days since modification since startup of the script, so:

      my $age = -M $file; if ($age < 7) { # do something } # or directly if (-M $file < 7) { # do something }

      -- Hofmator