php man page for msgfmt_get_error_code

Query: msgfmt_get_error_code

OS: php

Section: 3

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

MSGFMT_GET_ERROR_CODE(3)						 1						  MSGFMT_GET_ERROR_CODE(3)

MessageFormatter::getErrorCode - Get the error code from last operation

	Object oriented style

SYNOPSIS
public int MessageFormatter::getErrorCode (void )
DESCRIPTION
Procedural style int msgfmt_get_error_code (MessageFormatter $fmt) Get the error code from last operation.
PARAMETERS
o $fmt - The message formatter
RETURN VALUES
The error code, one of UErrorCode values. Initial value is U_ZERO_ERROR.
EXAMPLES
Example #1 msgfmt_get_error_code(3) example <?php $fmt = msgfmt_create("en_US", "{0, number} monkeys on {1, number} trees"); $str = msgfmt_format($fmt, array()); if(!$str) { echo "ERROR: ".msgfmt_get_error_message($fmt) . " (" . msgfmt_get_error_code($fmt) . ") "; } ?> Example #2 OO example <?php $fmt = new MessageFormatter("en_US", "{0, number} monkeys on {1, number} trees"); $str = $fmt->format(array()); if(!$str) { echo "ERROR: ".$fmt->getErrorMessage() . " (" . $fmt->getErrorCode() . ") "; } ?> The above example will output: ERROR: msgfmt_format: not enough parameters: U_ILLEGAL_ARGUMENT_ERROR (1)
SEE ALSO
msgfmt_get_error_message(3), intl_get_error_code(3), intl_is_failure(3). PHP Documentation Group MSGFMT_GET_ERROR_CODE(3)
Related Man Pages
datefmt_get_error_code(3) - php
datefmt_get_error_message(3) - php
msgfmt_parse(3) - php
numfmt_get_error_code(3) - php
numfmt_get_pattern(3) - php
Similar Topics in the Unix Linux Community
errpt
Adapter Errors and Link Errors
Adapter Errors and Link Errors
shell function help
Receiving: 4B436A3D 0313233216 T H fscsi0 LINK ERROR