mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-23 06:19:09 +01:00
removing possible CR/LF from content for ajax search result javascript, as it breaks the options
This commit is contained in:
parent
b407ea4c8e
commit
8770e59120
@ -634,6 +634,7 @@ class link_widget
|
|||||||
foreach($found as $id => $option)
|
foreach($found as $id => $option)
|
||||||
{
|
{
|
||||||
if (!is_array($option)) $option = array('label' => $option);
|
if (!is_array($option)) $option = array('label' => $option);
|
||||||
|
$option['label'] = str_replace(array("\r","\n"),array(" "," "),$option['label']);
|
||||||
$script .= "opt = select.options[select.options.length] = new Option('".addslashes($option['label'])."','".addslashes($id)."');\n";
|
$script .= "opt = select.options[select.options.length] = new Option('".addslashes($option['label'])."','".addslashes($id)."');\n";
|
||||||
if (count($option) > 1)
|
if (count($option) > 1)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user