#!/mod/bin/jimsh package require cgi source /mod/webif/lib/setup require ts.class pretty_size puts "Content-Type: text/html\r\n\r\n" cgi_input #cgi_dump set rfile [cgi_get file] set ts [ts fetch $rfile] set dir [file dirname $rfile] set len [$ts duration 1] set esttime $([$ts size] / 5700000) header puts "
Make recordings smaller by removing unecessary frames

This process will remove freeview EPG data from the recording.
These data are not required and can increase the size of the recording file by as much as 20%.
Your original recording files will be retained in a folder called _original.
File:$rfile
Length:[clock format $len -format %T]
Size:[pretty_size [$ts size]] ([$ts get definition])
Time: Squeezing will take around [clock format $esttime -format "%T"]
Estimated Saving: Analysing file, please wait...

"