Coding standards
Security in ResourceSpace
Developer reference
Database
User api session functions
Geolocation functions
Storage test functions
Cli functions
Lang translation functions

cli_clear_status_block()

Description

Clear a previously rendered block and leave the cursor ready for ordinary logging.

Parameters

ColumnTypeDefaultDescription
&$rendered_rows: int
$rendered_rows int Number of status rows on screen. Reset to zero.

Return

void

Location

include/cli_functions.php lines 183 to 189

Definition

 
function cli_clear_status_block(int &$rendered_rows): void
{
    if (
$rendered_rows > 0) {
        
fwrite(STDOUT, "\r\033[2K" . str_repeat("\033[1A\r\033[2K", $rendered_rows - 1));
        
$rendered_rows = 0;
    }
}

This article was last updated 27th November 2026 18:35 Europe/London time based on the source file dated 27th November 2026 17:15 Europe/London time.