Controls the central heating system and the lights.

Dependencies:   1-wire clock crypto fram log lpc1768 net web wiz mbed

web-this/home/web-home-html.c

Committer:
andrewboyson
Date:
2022-11-12
Revision:
8:8ac076ce51af
Parent:
0:22b158d3c76f

File content as of revision 8:8ac076ce51af:

#include "http.h"
#include "web-add.h"

void WebHomeHtml()
{
    HttpOk("text/html; charset=UTF-8", "no-cache", NULL, NULL);
    WebAddHeader("Home", NULL, "radiator.js");
    
    HttpAddText("<a href='/radiator' class='hamburger'>\r\n");
        HttpAddText("<div class='bar'  ></div>\r\n");
        HttpAddText("<div class='space'></div>\r\n");
        HttpAddText("<div class='bar'  ></div>\r\n");
        HttpAddText("<div class='space'></div>\r\n");
        HttpAddText("<div class='bar'  ></div>\r\n");
    HttpAddText("</a>\r\n");
    HttpAddText("<br/>\r\n");
    HttpAddText("<br/>\r\n");
    
    HttpAddText("<div id='ajax-date-local'></div>\r\n");
    HttpAddText("<br/>\r\n");
    WebAddAjaxLabelledSuffix("Hall temperature"  , "ajax-hall-html", "&deg;C");
    HttpAddText("<br/>\r\n");
    WebAddAjaxInputToggle   ("Radiators"         , "ajax-radiators-on-toggle", "htg-chg-override");
    HttpAddText("<br/>\r\n");
    WebAddAjaxInputToggle   ("Hot water priority", "ajax-hw-prot-toggle"     , "htg-chg-hw-prot" );
    HttpAddText("<br/>\r\n");
    WebAddAjaxInputToggle   ("Winter mode"       , "ajax-mode-toggle"        , "htg-chg-mode"    );
    HttpAddText("<br/>\r\n");

    WebAddEnd();
}