public static function nocache(): bool
    {
        if (!headers_sent()) {
            header('Expires: Wed, 11 Jan 1984 05:00:00 GMT');
            header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
            header('Cache-Control: no-cache, must-revalidate, max-age=0');
            header('Pragma: no-cache');

            return true;
        }

        return false;
    }
public static function nocache(): bool
    {
        if (!headers_sent()) {
            header('Expires: Wed, 11 Jan 1984 05:00:00 GMT');
            header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
            header('Cache-Control: no-cache, must-revalidate, max-age=0');
            header('Pragma: no-cache');

            return true;
        }

        return false;
    }
public static function nocache ( ) : bool { if ( ! headers_sent ( ) ) { header ( 'Expires: Wed, 11 Jan 1984 05:00:00 GMT' ) ; header ( 'Last-Modified: ' . gmdate ( 'D, d M Y H:i:s' ) . ' GMT' ) ; header ( 'Cache-Control: no-cache, must-revalidate, max-age=0' ) ; header ( 'Pragma: no-cache' ) ; return true ; } return false ; }
Sets the headers to prevent caching for the different browsers.
Different browsers support different nocache headers, so several
headers must be sent so that all of them get the point that no caching should occur

@return boolean

@codeCoverageIgnore
Sets the headers to prevent caching for the different browsers . Different browsers support different nocache headers so several headers must be sent so that all of them get the point that no caching should occur