-
Notifications
You must be signed in to change notification settings - Fork 7.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Closes GH-5807.
- Loading branch information
Showing
3 changed files
with
32 additions
and
5 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--TEST-- | ||
Bug #79787 mb_strimwidth does not trim string | ||
--SKIPIF-- | ||
<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?> | ||
--FILE-- | ||
<?php | ||
echo mb_strimwidth("一二三", 0, 4, '.', 'UTF-8')."\n"; | ||
echo mb_strimwidth("一二三", 0, 5, '.', 'UTF-8')."\n"; | ||
echo mb_strimwidth("一二三", 0, 6, '.', 'UTF-8')."\n"; | ||
echo mb_strimwidth("abcdef", 0, 4, '.', 'UTF-8')."\n"; | ||
echo mb_strimwidth("abcdef", 0, 5, '.', 'UTF-8')."\n"; | ||
echo mb_strimwidth("abcdef", 0, 6, '.', 'UTF-8')."\n"; | ||
?> | ||
--EXPECT-- | ||
一. | ||
一二. | ||
一二三 | ||
abc. | ||
abcd. | ||
abcdef |