Actions
Bug #1996
closedcarriage returns in text area when tab display as click overlib errors
Description
When adding a carriage return to a text area field and the tab it is on is set to be a click overlib it will generate a fatal js error resulting in the overlib failing.
Updated by scharles about 14 years ago
I have fixed this problem in my code base. I will attempt to post the correction in the bug ticket as wel.
The problem is in the \components\com_comprofiler\plugin\user\plug_cbcore\cb.core.php file.
Line 101 reads:
return str_replace( "\n", '<br />', parent::getField( $field, $user, $output, $reason, $list_compare_types ) );
It should read:
return str_replace( '\n', '<br />', parent::getField( $field, $user, $output, $reason, $list_compare_types ) );
The quotes around the \n should be single quotes not double quotes.
Steve
Updated by scharles about 14 years ago
Actually this is better... add the nl2br function to the line as well:
return nl2br(str_replace( '\n', '<br />', parent::getField( $field, $user, $output, $reason, $list_compare_types ) ));
Updated by beat almost 14 years ago
- Assignee set to beat
- Target version set to CB 1.3
- % Done changed from 0 to 100
- Estimated time set to 0:30 h
Fixed differently in r1295 .
Actions