Function _shorten
Shorten a string for the given length
Package: PHPLucidFrame\Core
Copyright: Copyright (c), PHPLucidFrame.
License: MIT License This source file is subject to the MIT license that is bundled with this source code in the file LICENSE
Author: Sithu sithu@phplucidframe.com
Located at helpers/utility_helper.php
Copyright: Copyright (c), PHPLucidFrame.
License: MIT License This source file is subject to the MIT license that is bundled with this source code in the file LICENSE
Author: Sithu sithu@phplucidframe.com
Located at helpers/utility_helper.php
string |
$str |
A plain text string to be shorten |
integer |
$length = 50 |
The character count |
boolean |
$trail = '...' |
To append <code>...</code> or not. <code>null</code> to not show |
string
|
The shortent text string |