hyperlink gone after edit
hyperlink gone after edit
Hi,
i use this to display hyperlink for one of the column data.
{ data: "Position",
"fnCreatedCell": function (nTd, sData, oData, iRow, iCol) {
$(nTd).html("<a href='http://www.google.com'>"+oData.Position+"</a>");
}
}
i also implemented Editor for the table. after edit completed, the edited data don't have the hyperlink anymore. kindly advise. attached the screenshot
Answers
Use
columns.render
to create the cell's content (see the renderers manual). You can't usecolumns.createdCell
for this because it is only executed once in the cell's life-time - when it is created (i.e. not when it is updated).Allan