How to get another column's value when adding a link to a column's value
How to get another column's value when adding a link to a column's value

Hey,
Brilliant plugin.
I have this code which adds a link to a column's values:
columnDefs: [
{
targets: 0,
render: function (data, type, row, meta)
{
if (type === 'display')
{
data = '<a href="FormToEdit.php?everything=' + encodeURIComponent(data) + '">' + data + '</a>';
}
return data;
}
}],
I have a column next to this with an ID value, I'd like to use that ID value where the link in the column is "everything=OTHER-COLUMN-VALUE" - how can I do this?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
The third parameter,
row
, contains all the data for the row, so you can grab it from there,Colin
Brilliant!!! - thanks