.click() event for div after page/filter/sort
.click() event for div after page/filter/sort
whoopes
Posts: 9Questions: 0Answers: 0
Sloppy coding aside ...
.click() events only seem to work when the table is put back into the state it loaded. Same phenomenon with IE as with Firefox. Breakpoints with Firebug don't even trigger. I'm quite a newbie and quite perplexed. Any help would be appreciated.
My javascript initialization;
[code]
$(document).ready(function() {
oTable = $('#ctl00_ContentPlaceHolder1_GridView1').dataTable({
"bJQueryUI": true,
"sPaginationType": "full_numbers",
"bAutoWidth": true,
"iDisplayLength": 3,
"bSortClasses": false,
"bStateSave": false,
"aoColumns": [
/* RQ_ID */{"bSearchable": false, "bSortable": false },
/* RQ_ID */null,
/* REQUESTOR */null,
/* ENTERED_BY */null,
/* ENTR_DTT */null,
/* TOTAL_EST_REQ_AMT */{"bSearchable": false },
/* MANUAL */{"bSearchable": false },
/* VDE */{"bSearchable": false },
/* MRP */{"bSearchable": false }
]
});
$('.vde').click(function() {
var rqid = $(this).attr('id').split('_')[0];
if (confirm('Are you sure that you want to remove requisition ' + rqid + ' from Costpoint?') === true) {
DeleteRQ(rqid, 'V', this);
}else{
return false;
}
});
});
[/code]
My table:
[code]
Rq IDReqEntered ByCP Received DateReq TotalMANUALVDEMRP
VR0000283DonnaDonna8/11/2010 8:49:28 AM630.00
VR0000284PhilPhil8/11/2010 8:49:29 AM683.11
VR0000304EdEd8/12/2010 4:00:01 PM0.01
VR0000305AnneAnne8/12/2010 4:00:02 PM0.01
VR0000306JeffJeff8/16/2010 3:54:13 PM3600.00
[/code]
.click() events only seem to work when the table is put back into the state it loaded. Same phenomenon with IE as with Firefox. Breakpoints with Firebug don't even trigger. I'm quite a newbie and quite perplexed. Any help would be appreciated.
My javascript initialization;
[code]
$(document).ready(function() {
oTable = $('#ctl00_ContentPlaceHolder1_GridView1').dataTable({
"bJQueryUI": true,
"sPaginationType": "full_numbers",
"bAutoWidth": true,
"iDisplayLength": 3,
"bSortClasses": false,
"bStateSave": false,
"aoColumns": [
/* RQ_ID */{"bSearchable": false, "bSortable": false },
/* RQ_ID */null,
/* REQUESTOR */null,
/* ENTERED_BY */null,
/* ENTR_DTT */null,
/* TOTAL_EST_REQ_AMT */{"bSearchable": false },
/* MANUAL */{"bSearchable": false },
/* VDE */{"bSearchable": false },
/* MRP */{"bSearchable": false }
]
});
$('.vde').click(function() {
var rqid = $(this).attr('id').split('_')[0];
if (confirm('Are you sure that you want to remove requisition ' + rqid + ' from Costpoint?') === true) {
DeleteRQ(rqid, 'V', this);
}else{
return false;
}
});
});
[/code]
My table:
[code]
Rq IDReqEntered ByCP Received DateReq TotalMANUALVDEMRP
VR0000283DonnaDonna8/11/2010 8:49:28 AM630.00
VR0000284PhilPhil8/11/2010 8:49:29 AM683.11
VR0000304EdEd8/12/2010 4:00:01 PM0.01
VR0000305AnneAnne8/12/2010 4:00:02 PM0.01
VR0000306JeffJeff8/16/2010 3:54:13 PM3600.00
[/code]
This discussion has been closed.
Replies
Allan
Allan