mvm_gui_open_webserver — Open a GUI webserver.
mvm_gui_open_webserver( : : Port, RootDir, AllowRemote : ServerHandle)
Opens a GUI webserver which listens for connections at the local host on port Port.
The server supplies a HTTP server serving files from the directory RootDir and a WebSocket server.
The returned ServerHandle should be used to close the webserver at the end of the program with mvm_gui_close_webserver.
The root directory of the server must be an absolute path to an existing directory or a path relative to the current working directory (see also set_current_dir). The directory is resolved immediately when
this operator is executed. It is therefore OK to change the working directory afterwards.
This operator returns a handle. Note that the state of an instance of this handle type may be changed by specific operators even though the handle is used as an input parameter by those operators.
Port (input_control) integer → (integer)
GUI server port
Default value: 9980
RootDir (input_control) string(-array) → (string)
root directory. Only files in this directory or in its subdirectories are accessible.
Default value: ''
AllowRemote (input_control) string → (string)
allow remote clients (contrary to allowing only access by the local host)
Default value: 'true'
List of values: 'false', 'true'
ServerHandle (output_control) serial → (handle)
GUI server handle
mvm_gui_open_webserver (9980, 'client/app/', true, ServerHandle)
mvm_gui_close_webserver,
close_handle,
mvm_gui_open_webclient
Foundation