aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xGradeBook.tcl2
-rwxr-xr-xGradeBook_lib.tcl4
2 files changed, 6 insertions, 0 deletions
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 "<div class=\"footer\">"
+ puts "Execution time $execution_time seconds. <br>"
puts "GradeBook $VERSION code is written by Eugeniy E. Mikhailov"
puts "</div>"
}