From OpenSCADAWiki
Jump to: navigation, search

Modules of the WEB-interface

Modules of the user interface (UI) designed to work with the HTTP module, should indicate the information field "SubType" in the value "WWW" and "Auth" field in the value "1", if the module requires an authentication at login. For communication of the HTTP module and the UI modules an advanced communication mechanism is used. This mechanism involves export of interface functions. In this case, the UI modules must export only one generic function for all methods:

  • void HTTP(const string &meth, const string &uri, string &page, vector<string> &vars, const string &user, TProtocolIn *iprt);:
meth — method of the request;
uri — local address of the request;
page — page with the answer;
sender — address of the sender;
vars — variables of the request;
user — user, can contain previous user in the second line;
iprt — pointer to an input part object of the protocol.