MyBB Community Forums

Full Version: my_wordwrap issue
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi,

seems that 1.6.4 have some issue with muy_wordwrap.

unfortunatly i am not a regex master, so i can't say why is not working.

the issue is that links get splitted in the middle, expecially long ed2k links


here is an example

<a href="ed2k://|file|very.long.name.with
.some.dash-and.some.dot.blabllab%20blalba12345bla.bla|347900672|5747AFA0DC93AAD4016354BD9F1F608|/">

the hash is obviusly wrong (i dont want to post a valid ed2k link) Smile

i have changed the my_wordwrap function from 1.6.3 and the problem was solved Smile

can you please have a check to wordwrap function with that testcase?
any news?
my_wordwrap() is on line 4,126 of ./inc/functions.php. I'm terrible with regular expressions as well, but you might be able to come up with something at text2re.com.
my_wordwrap does not break up HTML tags, URLs or unicode references.
(2011-09-17, 12:15 AM)Masayoshi Wrote: [ -> ]my_wordwrap does not break up HTML tags, URLs or unicode references.
Look at his example; the regular expressions won't match that as a URL so it will break it up.
That's because that's not a real URL. Toungue
(2011-09-17, 01:49 AM)Masayoshi Wrote: [ -> ]That's because that's not a real URL. Toungue
Sure it is.

I'll see if I can modify the regular expressions to treat it like a URL. Like I said, I'm terrible with them but I'll see what I can do.
http://en.wikipedia.org/wiki/Ed2k_URI_scheme

Reading that alone should give you an idea of the nature of the website that would use these kinds of links.
(2011-09-17, 02:02 AM)Masayoshi Wrote: [ -> ]http://en.wikipedia.org/wiki/Ed2k_URI_scheme

Reading that alone should give you an idea of the nature of the website that would use these kinds of links.
For all we know he is sharing Linux distributions. Regardless, this is more of a Code Modification request so there's no need to sharpen your pitchfork just yet.
You don't share linux distros with that service. Also in his post, he states:

Quote:the hash is obviusly wrong (i dont want to post a valid ed2k link)

Toungue
Pages: 1 2