ID: 37846 User updated by: bugs dot php dot net at jonatan dot com Reported By: bugs dot php dot net at jonatan dot com -Status: Bogus +Status: Open Bug Type: Strings related Operating System: Mac OS X 10.4.6 PHP Version: 5.1.4 New Comment:
Jesus H. Christ, will you please try to actually read the bug report before closing it as bogus. Again: I URGE you to look at the expected result and the actual result and consider why wordwrap() thinks "Some text" fits on one line while "Some text" doesn't, given that they both start at the beginning of a line. If you find the reproduction code formatting confusing, try reformatting it as such: <?php $input = 'Some tex Some tex Some text Some tex Some text Some tex'; echo '<pre>'.wordwrap( $input, 9 )."</pre>\n"; ?> Previous Comments: ------------------------------------------------------------------------ [2006-06-20 13:22:17] [EMAIL PROTECTED] . ------------------------------------------------------------------------ [2006-06-20 13:17:00] bugs dot php dot net at jonatan dot com Wow, I don't know how it's possible to misunderstand such a simple bug report so extensively. ------------------------------------------------------------------------ [2006-06-20 11:51:25] [EMAIL PROTECTED] $s = ' s '. ' t '; is equal to ' s t ' If you really want to get several text lines - you need to use "" and \n. ------------------------------------------------------------------------ [2006-06-19 22:36:26] bugs dot php dot net at jonatan dot com unbogusing bug ------------------------------------------------------------------------ [2006-06-19 16:31:47] bugs dot php dot net at jonatan dot com You seem to be just as confused as the other guy. ;-) Sure, I guess the slight vagueness of the documentation could allow you to argue that wordwrap() wraps the third line incorrectly and the fifth one correctly instead of the other way around. But that doesn't negate the fact that this is a bug, it would just make it a much bigger bug, affecting the majority of lines wrapped by wordwrap() instead of the minority. Also note that your claim is refuted by the examples in the documentation, specifically the line "jumped over the lazy" which is 20 characters long. I urge you to look at the expected result and the actual result and consider why wordwrap() thinks "Some text" fits on one line while "Some text" doesn't, given that they both start at the beginning of a line. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/37846 -- Edit this bug report at http://bugs.php.net/?id=37846&edit=1