MyBB Community Forums

Full Version: long string bug
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Sample long string:

12345678901234567890123456789-123456789012345678901234567890123456789012345678901234567890

12345678901234567890123456789/123456789012345678901234567890123456789012345678901234567890

12345678901234567890123456789 123456789012345678901234567890123456789012345678901234567890

123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890
Erroneous!                                                                      ^


After the 81th character, a sort of unicode sequence is inserted. With normal text, no strings longer than 80 characters occur, but when an URL exceeds 80 characters, this may become a serious problem. To be precise: a URL which is separated with slashes don't represent a problem, only when a part without slashes exceeds 80 characters, e.g. a URL with al long #-type page target like in this example fails:
http://de.wikipedia.org/wiki/Vermögensve....C3.B6gens

The erroneous behaviour is found with MyBB 1.6.11.
You could increase or turn off word-wrap in ACP -> Configuration -> Settings -> Posting -> Number of Characters before Word Wrapping Occurs.
Thanks for your contribution to solve this problem. Line wrap only applies to text sections with fixed formatting. So for normal cases, the value of the parameter is not important. However: the problem also occurs when a link is embedded in [url]-sequences. Since most of those sequences use a simple text in place of the (invisible) link content, the code should better not line wrap in such cases.