Collections functions
General functions
Render functions
Theme permission functions
Resource functions

iiif_error()

Description

Handle a IIIF error.

Parameters

ColumnTypeDefaultDescription
$errorcode integer 404 The error code
$errors array array An array of errors

Return

void

Location

include/api_functions.php lines 376 to 385

Definition

 
function iiif_error($errorcode 404$errors = array())
    {
    global 
$iiif_debug;
    if(
function_exists("http_response_code"))
        {
        
http_response_code($errorcode); # Send error status
        
}
    echo 
json_encode($errors);     
    exit();
    }

This article was last updated 26th June 2022 02:35 Europe/London time based on the source file dated 14th May 2022 09:10 Europe/London time.