From 57df626499462f60f7f6b06710075862a6590f29 Mon Sep 17 00:00:00 2001 From: Eugeniy Mikhailov Date: Fri, 11 Mar 2011 10:47:56 -0500 Subject: addded execution time output to the footer Ignore-this: 918cef16078eecc69e3ff6247cf2d6d5 darcs-hash:20110311154756-067c0-c082784f81cda43c77c21591ee2f2c9b5821c226.gz --- GradeBook.tcl | 2 ++ GradeBook_lib.tcl | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/GradeBook.tcl b/GradeBook.tcl index a8c5b00..c3fc6bb 100755 --- a/GradeBook.tcl +++ b/GradeBook.tcl @@ -9,6 +9,8 @@ package require sqlite3 package require ncgi package require md5 +set execution_start_time [clock microseconds] + source ./GradeBook_lib.tcl ::ncgi::parse diff --git a/GradeBook_lib.tcl b/GradeBook_lib.tcl index 69385e7..f0c2440 100755 --- a/GradeBook_lib.tcl +++ b/GradeBook_lib.tcl @@ -552,7 +552,11 @@ proc htmlTop {permission_list} { proc htmlFooter {permission_list} { array set permission $permission_list global VERSION + global execution_start_time + set execution_end_time [clock microseconds] + set execution_time [ format "%.3g" [expr { ($execution_end_time - $execution_start_time)/1e6}] ] puts "
" + puts "Execution time $execution_time seconds.
" puts "GradeBook $VERSION code is written by Eugeniy E. Mikhailov" puts "
" } -- cgit v1.2.3