forked from hummypkg/webif
8d36fe22dd
git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@687 2a923420-c742-0410-a762-8d5b09965624
33 lines
523 B
Plaintext
Executable File
33 lines
523 B
Plaintext
Executable File
#!/mod/bin/jimsh
|
|
|
|
package require cgi
|
|
source /mod/var/mongoose/lib/setup
|
|
require ts.class pretty_size
|
|
|
|
puts "Content-Type: text/html\r\n"
|
|
|
|
cgi_input
|
|
#cgi_dump
|
|
|
|
header
|
|
|
|
set rfile [cgi_get file]
|
|
set ts [ts fetch $rfile]
|
|
if {[catch {$ts get file}]} {
|
|
puts "Invalid TS file, '$rfile'"
|
|
exit
|
|
}
|
|
|
|
puts {
|
|
<script type="text/javascript" src="play.js"></script>
|
|
<fieldset class=cleft style="margin: 0 1em 1em 1em">
|
|
<legend>VLC Player</legend>
|
|
<div>
|
|
}
|
|
puts "Now playing: $rfile, [$ts duration] minutes."
|
|
puts {
|
|
</div>
|
|
</fieldset>
|
|
}
|
|
|