substr() is returning 28 characters instead of 25.
substr()
$nature_goods is the input field, where user can enter string containing special characters.
$nature_goods
In substr() function third parameter is used to set the length not to set the position. For more details please visit
http://php.net/manual/en/function.substr.php