]> git.plutz.net Git - serve0/blobdiff - actions/watch.sh
set up remote player in local.opts
[serve0] / actions / watch.sh
index 596ca32ad43c96bcd7d4c26410d2369f9b57ad34..1ba0954192943b07529c80d842b9670b3639cdf5 100755 (executable)
@@ -41,11 +41,9 @@ fi
 
 case "$_COOKIE[watch]" in
   raspi)
-    #rpiaddr="http://atoemchen.helmchyn.no-ip.biz/?action=watch"
-    #redirect "${rpiaddr}&url=$(urlsafe "http://${HTTP_HOST}/${videourl}")&return=$(urlsafe "http://${HTTP_HOST}/${_POST[page]}")"
-    ncat atoemchen 80 >&- <<-EOF
+    ncat "$RHOST" "$RPORT" >&- <<-EOF
        GET /?action=watch&url=$(urlsafe "http://${HTTP_HOST}/${videourl}") HTTP/1.1$(printf \\r)
-       Host: atoemchen$(printf \\r)
+       Host: ${RHOST}$(printf \\r)
        $(printf \\r)
        EOF
     redirect "?p=playctl&${watch_link}w=$(urlsafe "${_POST[page]}#${_GET[i]}")"