httpClear
Server-side
Caution
This function works only in the HTTP interface, meaning in .html files - it is not available in .lua files.
This function removes all text from the current HTML output.
Syntax
bool httpClear ( )Returns
Returns true if the output buffer was cleared successfully, false otherwise.
- bool: result
Code Examples
server
This example creates a simple HTTP interface for a server resource. When you open the resource page in a browser, you will see a white page with text indicating that there are players on the server. If the server is empty, the page will be completely blank.
<html> <head> <title>Hello</title> </head>
<body> There are some players on the server! </body></html>
<* if (#getElementsByType('player') == 0) then httpClear() end*>