Hello Sir,
I just wanna ask I have a table inside my ajax success call just like this below.
`$('#btn-inquire-transmittal-number').click(function(e){
e.preventDefault();
$('#window-transmittal-inquiry').hide(1000);
var inputtextval = $('#transmittal_number_inquiry').val();
$("#modalTransmittalInquiry").modal('show');
$.ajax({
url: "getTransmittalNum.php",
type: "POST",
data: {'transmittal_number_inquiry' : inputtextval},
datatype: 'json',
success: function(data){
$('#modalTransmittalInquiry').modal('show');
$('#modal-content-result').html('<table class="table table-condensed tablehead table-sortable" id="table_inquiry" style="width:99%;">' +
'<tr>' +
'<thead>' +
'<th style="text-wrap:normal">Transmittal #</th>' +
'<th>Transmittal Date</th>' +
'<th>Sender Name</th>' +
'<th>Department</th>' +
'<th>Invoice #</th>' +
'<th>Amount</th>' +
'<th>Document Type</th>' +
'<th>Vendor Name</th>' +
'<th>Remark</th>' +
'<th>Action</th>' +
'</thead>' +
'<tr>' +
'</table>');
var trHTML = '<tr>' +
'<tbody>' +
'<td><h6>' + data.transid + '</h6></td>' +
'<td><h6>' + data.transdate + '</h6></td>' +
'<td><h6>' + data.sender_name + '</h6></td>' +
'<td><h6>' + data.department + '</h6></td>' +
'<td><h6>' + data.document_number + '</h6></td>' +
'<td><h6>' + data.total_amount + '</h6></td>' +
'<td><h6>' + data.document_type + ' - ' + data.document_description + '</h6></td>' +
'<td><h6>' + data.vendor_name + '</h6></td>' +
'<td><h6>' + data.remarks + '</h6></td>' +
'<td><h6>' +
'<a href="acknowledge_process.php?id=$id"><button type="button" class="btn btn-success"><i class="fa fa-check-circle fa-fw"></i></button></a>' +
'<a href="incomplete_process.php?id=$id"><button type="button" class="btn btn-danger" ><i class="incomplete fa fa-times-circle fa-fw"></i></button></a>' +
'<a href="onprocess_process.php?id=$id"><button type="button" class="btn btn-warning" ><i class="onprocess fa fa-cogs fa-fw"></i></button></a>' +
'</h6></td>' +
'</tbody>' +
'</tr>';
$('#table_inquiry').append(trHTML);
},
error:function(){
alert('Error occured..');
}
});
});`
I want to use the jquery plugin I have a problem where I put the code that will call my table id. Thank you in advance.
Hello Sir,
I just wanna ask I have a table inside my ajax success call just like this below.
`$('#btn-inquire-transmittal-number').click(function(e){
e.preventDefault();
$('#window-transmittal-inquiry').hide(1000);
var inputtextval = $('#transmittal_number_inquiry').val();
I want to use the jquery plugin I have a problem where I put the code that will call my table id. Thank you in advance.