Created
March 10, 2014 08:20
-
-
Save zhouyuan24/9461272 to your computer and use it in GitHub Desktop.
php截取最后一个字符串
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$str = "1,2,3,4,5,6,"; | |
$newstr = substr($str,0,strlen($str)-1); | |
echo $newstr; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
中文会乱码的样子……