Jesus · Bible · HTML · CSS · JS · PHP · SVG · Applications

pcntl_strerror

Description

The pcntl_strerror of PCNTL for PHP retrieves the system error message associated with the given errno.

Syntax

pcntl_strerror(
    int $error_code
): string

Parameters

error_code

The error code.

Return

Returns the error description.

Examples

1 · error_code

<?

$error_code = pcntl_get_last_error();

$return = pcntl_strerror($error_code);

echo $return;

?>
Success

2 · error

<?

$flags = CLONE_NEWNS;

pcntl_unshare($flags);

$error_code = pcntl_get_last_error();

$return = pcntl_strerror($error_code);

echo $return;

?>
Operation not permitted
HomeMenu