IntlChar isgraph() function in PHP

The IntlChar isgraph()function checks that the entered value is a graphic character or not.

Syntax

bool IntlChar::isgraph (val)

Parameters

  • val − An integer or character encoded as a UTF-8 string.

Return

The IntlChar isgraph() function returns TRUE of val is a graphic character.

Example

The following is an example −

";
   var_dump(IntlChar::isgraph("r"));
   echo "
";    var_dump(IntlChar::isgraph("n"));    echo "
";    var_dump(IntlChar::isgraph("j"));    echo "
"; ?>

Output

The following is the output −

bool(true)
bool(false)
bool(false)
bool(true)
Updated on: 2019-12-30T10:13:27+05:30

127 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements