Help for this page

Select Code to Download


  1. or download this
    chomp($value = <STDIN>); 
    if ($value =~ m#(0[1-9]|[12][0-9]|3[01])[-/.](0[1-9]|1[012])[- /.](\d\
    +d\d\d)#) { 
    ...
    } else { 
        print $value; print "not a date"; 
    }
    
  2. or download this
    se DateTime::Format::Strptime;
    
    ...
    } else {
        print "not a date\n";
    }