multiple custom filters
multiple custom filters
Hi,
I have multiple custom filters in my form but the second one isn't working. Is it something stupid I am doing?
[code]
$(document).ready(function() {
// Initialise the table
oTable = $('#admintable').dataTable({
bAutoWidth: false,
sPaginationType: "full_numbers",
});
$("select#purpose").change(function () {
var val = $("select#purpose option:selected").attr('value');
oTable.fnFilter (val,2,false);
});
$("select#usergroup").change(function () {
var val = $("select#usergroup option:selected").attr('value');
oTable.fnFilter (val,3,false);
});
});
Purpose
Show all
{VAR_PurposeSel[ArticleAdmin]}
User Group
Show all
{VAR_UsergroupSel[ArticleAdmin]}
[/code]
Please ignore the {VAR_... This is how I populate the drop downs within my project through php. The first one works fine with no problem but the second has no effect and no error.
Thanks
k0r54
I have multiple custom filters in my form but the second one isn't working. Is it something stupid I am doing?
[code]
$(document).ready(function() {
// Initialise the table
oTable = $('#admintable').dataTable({
bAutoWidth: false,
sPaginationType: "full_numbers",
});
$("select#purpose").change(function () {
var val = $("select#purpose option:selected").attr('value');
oTable.fnFilter (val,2,false);
});
$("select#usergroup").change(function () {
var val = $("select#usergroup option:selected").attr('value');
oTable.fnFilter (val,3,false);
});
});
Purpose
Show all
{VAR_PurposeSel[ArticleAdmin]}
User Group
Show all
{VAR_UsergroupSel[ArticleAdmin]}
[/code]
Please ignore the {VAR_... This is how I populate the drop downs within my project through php. The first one works fine with no problem but the second has no effect and no error.
Thanks
k0r54
This discussion has been closed.
Replies
Please ignore, another look at the source code and my php was playing up. Sorry to waste the post!
I do have a slight other issue. For some reason I have noticed the filters seem to fail on & and brackets ().
Is there any known reason for this?