String

A string is series of characters, where a character is the same as a byte. This means that PHP only supports a 256-character set, and hence does not offer native Unicode support.

<?php

$string = 'Hello world';

?>

Documentation

See also Character Encoding for PHP Developers: Unicode, UTF-8 and ASCII and PHP 8.0: New Stringable interface.

Related : Stringable, Single Quotes Strings, Double Quotes Strings, Magic Methods, sprintf, sprintf, Concatenation, Curly Brackets, Format, Heredocs, Interpolation, Nowdocs, Scalar Types, String Interpolation, Case Sensitivity, negative-index, Scalar Types, printf(), BackedEnum, Callbacks, Empty String, PHP Natives, Escape Character, file_get_contents(), Offset, Text, Slug, String Increment, strtolower(), strtoupper()

Related packages : symfony/string, voku/stringy