]> git.plutz.net Git - serve0/commitdiff
properly escape link urls
authorpaul <paul@plutz.net>
Sat, 12 May 2018 23:51:47 +0000 (23:51 +0000)
committerpaul <paul@plutz.net>
Sat, 12 May 2018 23:51:47 +0000 (23:51 +0000)
svn path=/trunk/; revision=197

templates/view.html.sh

index c0a41193e4f827d00a1702b1d43940ea6428a09c..b2c48db0e22f3c9232237903d6a22d9a7ff57e43 100755 (executable)
@@ -44,11 +44,11 @@ cat <<EOF
 
 
 <div id="videoview">
-  <h1>$info</h1>
+  <h1>$(htmlsafe "$info")</h1>
 
-  <a href="$video">Download</a>
+  <a href="$(urlsafe "$video")">Download</a>
   <video autoplay controls>
-    <source src="$video" type='video/mp4; codecs="avc1.4D401E, mp3"'>"
+    <source src="$(urlsafe "$video")" type='video/mp4; codecs="avc1.4D401E, mp3"'>"
   </video>
 
   <span class="info length">$(printf "%d:%02d min" $(($length / 60)) $(($length % 60)) )</span>