Custom filtering on column with hrefs
Custom filtering on column with hrefs
I'm sure this has been covered before but I just can't find it via search. I have a number of custom filters, all working fine as long as the table cell is text. But when the cell includes a link the filter fails. Clearly aData[0] does not return just the text, but how do I get the text only?
Code snippet (Title_name_pulldown is a element):
$.fn.dataTableExt.afnFiltering.push(
function( oSettings, aData, iDataIndex ) {
titleName = document.getElementById("Title_name_pulldown");
if (titleName) {
if (titleName.value != aData[0] && titleName.value != 'All')
result = false;
}
Filter works in cases like this:
Title
Filter fails in cases like this:
Title
Code snippet (Title_name_pulldown is a element):
$.fn.dataTableExt.afnFiltering.push(
function( oSettings, aData, iDataIndex ) {
titleName = document.getElementById("Title_name_pulldown");
if (titleName) {
if (titleName.value != aData[0] && titleName.value != 'All')
result = false;
}
Filter works in cases like this:
Title
Filter fails in cases like this:
Title
This discussion has been closed.