get only first letterof string php code example
Example 1: php get first character of string
$firstStringCharacter = substr("hello", 0, 1);
Example 2: php nth characters from end of string
$rest = substr("abcdef", -3, 1); // returns 'd'
$firstStringCharacter = substr("hello", 0, 1);
$rest = substr("abcdef", -3, 1); // returns 'd'