Allows my home wiz lights to be timed on and off according to a schedule.
Diff: web/web-wiz-script.c
- Revision:
- 0:9af80a39adcc
diff -r 000000000000 -r 9af80a39adcc web/web-wiz-script.c --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/web/web-wiz-script.c Mon May 10 08:24:22 2021 +0000 @@ -0,0 +1,17 @@ +#include "http.h" + +//Use http://tomeko.net/online_tools/cpp_text_escape.php to convert from text to c-multiline +//Use http://tomeko.net/online_tools/cpp_text_unescape.php to convert from c-multiline to text + +static const char* script = +#include "../../web/common/web-ajax-class.inc" +#include "web-wiz-script.inc" +; +const char* WebWizScriptDate = __DATE__; +const char* WebWizScriptTime = __TIME__; + +void WebWizScript() +{ + HttpOk("application/javascript; charset=UTF-8", "max-age=3600", WebWizScriptDate, WebWizScriptTime); + HttpAddText(script); +}