Hello, I need to take a string and reduce it to a given amount of characters, chop and trim seem to take a substring to chop at but i need it to be a set number or characters can anyone help? Thanks
$numChars = 5; $newString = substr($string,0,$numChars);
Check here for more string handling function: http://ca3.php.net/manual/en/ref.strings.php
Thanks, thats perfect.
You're welcome 😃