remove ast two character of a string php code example Example: php remove last character from string $hell = substr('hello', 0, -1);