Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all articles
Browse latest Browse all 82755

proper way to pass variable to a js function in column

$
0
0

i note that whilst this works under columns, returning the value of myvar
{ data: null, render: function (data, type, row, meta){return data.myvar}}
which is equivalent to
{ data: 'myvar' }

this doesn't and returns a null
{ data: null, render: function (data, type, row, meta){return data.myvar.replace(/[,]+/g, " ")}}

what's the proper way to pass the myvar variable to a js function?


Viewing all articles
Browse latest Browse all 82755

Trending Articles