Collections functions
General functions
Node functions
Render functions
Theme permission functions
User functions
Resource functions

show_upgrade_in_progress()

Description

show_upgrade_in_progress message

Parameters

ColumnTypeDefaultDescription
$dbstructonly bool false - Indicates whether this is a full upgrade with migration scripts or just a check_db_structs()

Return

void

Location

include/render_functions.php lines 5169 to 5198

Definition

 
function show_upgrade_in_progress($dbstructonly=false)
    {
    global 
$lang;
    
$title = (isset($lang["upgrade_in_progress"])?$lang["upgrade_in_progress"]:"Upgrade in progress");
    
$message="This system is currently being upgraded by another process. Delete filestore/tmp/process_locks/* if this process has stalled." PHP_EOL;
    if(!
$dbstructonly)
        {
        
$upgrade_progress_overall=get_sysvar(SYSVAR_UPGRADE_PROGRESS_OVERALL);
        
$upgrade_progress_script=get_sysvar(SYSVAR_UPGRADE_PROGRESS_SCRIPT);
        
$message.=($upgrade_progress_overall===false '' $upgrade_progress_overall PHP_EOL);
        
$message.=($upgrade_progress_script===false '' 'Script status: ' $upgrade_progress_script PHP_EOL);
        }
    if(
PHP_SAPI == 'cli')
        {
        echo 
$message;
        }
    else
        {
        echo 
"<h1>{$title}</h1>";
        echo 
nl2br($message);
        
?>
        <script>
        setTimeout(function()
            {
            window.location.reload(true);
            }, 5000);
        </script>
        
        
}
    }

This article was last updated 19th March 2024 03:05 Europe/London time based on the source file dated 15th March 2024 17:00 Europe/London time.