####### jzLibrary.pl is an example of perl subroutine collections ##### # Author Jeff Zhuk ####################################################################### ################ getTime() delivers date and time as mm/dd/yy:HH-MM-SS sub getTime { local($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time); ########## perl time function return (($mon + 1) . "/" . $mday . "/" . $year . ":" . $hour . "-" . $min . "-" . $sec); #### . means concantanate !!! } ################ printHTML prints html format file #################### sub printHTML { local($info) = @_; ############# we get argument list this way print "< html > < head >< title >My Page< /title>< /head>"; print "< body bgcolor=ffffff>"; print "< pre>< h2> $info< /h2>< /pre>< /body>< /html>"; } 1; ########### required at the end of subroutine file