#!/bin/zsh
-# Copyright 2014, 2015 Paul Hänsch
+# Copyright 2014 2016 Paul Hänsch
#
# This file is part of Serve0.
#
# You should have received a copy of the GNU Affero General Public License
# along with Serve0. If not, see <http://www.gnu.org/licenses/>.
-. $_EXEC/pages/list.sh
-. $_EXEC/pages/tree.sh
+. $_EXEC/pages/common.sh
info="${_GET[i]}"
location="$(invalidate "${_GET[l]}" '(.*/)?\.\.(/.*)?|' /)"
length=0; width=0; height=0;
debug "Analysing video: $video"
-echo '' |mplayer -input nodefault-bindings -nosound -vo null -identify -frames 0 "$video" \
+printf '' |mplayer -input nodefault-bindings -nosound -vo null -identify -frames 0 "$video" \
| sort \
| sed -rn 's:ID_LENGTH=(.*)(\..*)$:\1:p;
s:ID_VIDEO_HEIGHT=(.*):\1:p;