mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-23 14:28:45 +01:00
* infolog: when breaking overlong words into fitting pieces, do not break lines that are tested positive to contain links. (reported as Helpdesk issue #1324 in Stylite tracker)
This commit is contained in:
parent
b1db66a28e
commit
963542c912
@ -1048,9 +1048,13 @@ class infolog_ui
|
||||
// set blank behind all , and . if words are too long, apply wordwrap afterwards to make sure we get
|
||||
if (strlen($word)>75)
|
||||
{
|
||||
if (!(strpos($word,',')===false) && strpos($word,', ')===false) $word = str_replace(',',', ',$word);
|
||||
if (!(strpos($word,'.')===false) && strpos($word,'. ')===false) $word = str_replace('.','. ',$word);
|
||||
$word = wordwrap($word, 75, ' ', true);
|
||||
$buff = html::activate_links($word);
|
||||
if (strlen($buff) == strlen($word)) // no links -> try to break overlong words
|
||||
{
|
||||
if (!(strpos($word,',')===false) && strpos($word,', ')===false) $word = str_replace(',',', ',$word);
|
||||
if (!(strpos($word,'.')===false) && strpos($word,'. ')===false) $word = str_replace('.','. ',$word);
|
||||
$word = wordwrap($word, 75, ' ', true);
|
||||
}
|
||||
}
|
||||
$ckarray[] =$word;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user