mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 14:41:29 +01:00
strip html from caption in selectcols popup
This commit is contained in:
parent
151da7e0bd
commit
d7d28e75d5
@ -139,11 +139,14 @@ egwGrid.prototype.selectcolsClick = function(_at)
|
|||||||
for (var k in column_data)
|
for (var k in column_data)
|
||||||
{
|
{
|
||||||
var col = column_data[k];
|
var col = column_data[k];
|
||||||
|
// strip html from caption
|
||||||
|
var strippedCaption = col.caption.replace(/&(lt|gt);/g, function (strMatch, p1) {
|
||||||
|
return (p1 == "lt")? "<" : ">";});
|
||||||
|
strippedCaption = strippedCaption.replace(/<\/?[^>]+(>|$)/g,"");
|
||||||
menu_data.push(
|
menu_data.push(
|
||||||
{
|
{
|
||||||
"id": k,
|
"id": k,
|
||||||
"caption": col.caption,
|
"caption": strippedCaption,
|
||||||
"enabled": col.enabled,
|
"enabled": col.enabled,
|
||||||
"checkbox": true,
|
"checkbox": true,
|
||||||
"checked": col.visible
|
"checked": col.visible
|
||||||
|
Loading…
Reference in New Issue
Block a user