diff options
Diffstat (limited to 'package/wiviz/files/www/cgi-bin')
-rwxr-xr-x | package/wiviz/files/www/cgi-bin/wiviz/get.cgi | 15 | ||||
-rwxr-xr-x | package/wiviz/files/www/cgi-bin/wiviz/set.cgi | 3 |
2 files changed, 18 insertions, 0 deletions
diff --git a/package/wiviz/files/www/cgi-bin/wiviz/get.cgi b/package/wiviz/files/www/cgi-bin/wiviz/get.cgi new file mode 100755 index 000000000..161fc75ee --- /dev/null +++ b/package/wiviz/files/www/cgi-bin/wiviz/get.cgi @@ -0,0 +1,15 @@ +#!/bin/sh + +WIVIZ_PATH=wiviz + +echo Content-type: text/html +echo +killall -USR1 wiviz >/dev/null 2>&1 +if [ 0 -ne $? ] + then #### Wi-Viz daemon not running, start it + $WIVIZ_PATH >/dev/null </dev/null 2>&1 & + killall -USR1 wiviz > /dev/null + fi +echo "<html><head><script language='JavaScript1.2'>" +cat /tmp/wiviz-pipe +echo "</script></head><body></body></html>" diff --git a/package/wiviz/files/www/cgi-bin/wiviz/set.cgi b/package/wiviz/files/www/cgi-bin/wiviz/set.cgi new file mode 100755 index 000000000..17b47873a --- /dev/null +++ b/package/wiviz/files/www/cgi-bin/wiviz/set.cgi @@ -0,0 +1,3 @@ +#!/bin/sh +httpd -d $QUERY_STRING > /tmp/wiviz-cfg +killall -USR2 wiviz |