substr
php
string substr(string $lancuch, number $start , [number $length])Returns $length characters of $lancuch starting at $start. The first character is at position 0. If $length is omitted, returns the substring from $start to the end.
Example:
php
$zdanie = "Ada has a cat";
$kto = substr($zdanie, 0, 3);
print("Who: ".$kto);
$co = substr($zdanie, 10);
print("What: ".$co);Result:
Who: Ada What: cat