Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/461.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 下拉列表内容发生了变化,感谢@Aman的提示 $(function(){ $('#tableChart').dataTable( { // -------Function for formatting the table data _Php_Javascript_Jquery_Codeigniter_Datatable - Fatal编程技术网

Php 下拉列表内容发生了变化,感谢@Aman的提示 $(function(){ $('#tableChart').dataTable( { // -------Function for formatting the table data

Php 下拉列表内容发生了变化,感谢@Aman的提示 $(function(){ $('#tableChart').dataTable( { // -------Function for formatting the table data ,php,javascript,jquery,codeigniter,datatable,Php,Javascript,Jquery,Codeigniter,Datatable,下拉列表内容发生了变化,感谢@Aman的提示 $(function(){ $('#tableChart').dataTable( { // -------Function for formatting the table data elements------- "fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) { $.e

下拉列表内容发生了变化,感谢@Aman的提示
$(function(){
    $('#tableChart').dataTable( {
        // -------Function for formatting the table data elements-------
        "fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {


                $.each(aData, function (i, elem){                       
                    $('td:eq('+i+')', nRow).html( '<b><font color="#40A913">'+aData[i]+'</font></b>' );
                }) 
                return nRow;
        },



            "bAutoWidth": false,
            "bProcessing": true,
            "bLengthChange": false, // Remove the show list drop down button
            "bInfo": false,         // Remove info part under the table
            "bFilter" : false,      // Remove search box
            "bDestroy": true,           // Remove table & recreate table

            "bServerSide": false,

            "sAjaxSource": "<?php echo base_url(); ?>index.php/print_db_table/get_print_db_table/<?php echo $table_name; ?>",

    });         
});
<div class="container"> 
    <div class="holderForTableChart">   
        <table width ="100%" cellpadding="5" cellspacing="0" class="display" id="tableChart"> 
            <thead> 
                <tr id="tableHeadder" > 
                    <?php
                        foreach($table_header as $item):
                            $header = $item->name;
                            echo '<th>'.$header.'</th>' ;
                        endforeach;
                    ?>                                              
                </tr> 
                <tr>
                <td></td>
                <td>
                <select id=""></select>
                <select id=""></select>
                </td>
                <td>
                <select id=""></select>
                <select id=""></select>
                </td>
                <td>
                <select id=""></select>
                <select id=""></select>
                </td>
                <td>
                <select id=""></select>
                <select id=""></select>
                </td>
                </tr>
            </thead> 
            <tbody> 
                <tr> 
                    <td colspan="6" class="dataTables_empty">Loading data from server</td> 
                </tr> 
            </tbody> 
        </table>    
    </div>
</div>
var oTable = '';
$(function(){
    oTable = $('#tableChart').dataTable( {
        // -------Function for formatting the table data elements-------
        'fnRowCallback': function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
                $.each(aData, function (i, elem){                       
                    $('td:eq('+i+')', nRow).html( '<b><font color='#40A913'>'+aData[i]+'</font></b>' );
                }) 
                return nRow;
        },
            'bAutoWidth': false,
            'bProcessing': true,
            'bLengthChange': false, // Remove the show list drop down button
            'bInfo': false,         // Remove info part under the table
            'bFilter' : false,      // Remove search box
            'bDestroy': true,       // Remove table & recreate table
            'bServerSide': false,
            'sAjaxSource': '<?php echo base_url(); ?>index.php/print_db_table/get_print_db_table/<?php echo $table_name; ?>',

            'fnServerData': function (url, data, callback) {
                // Add new data 
                data.push({'name':'min_max_value', 'value':$('#min_max_value').val()});
                $.ajax({
                    'url': url,
                    'data': data,
                    'type': 'POST',
                    'success': callback,
                    'dataType': 'json',
                    'cache': true
                });
            },
    });         

    $('#min_max_value').change(function(){
        oTable.fnDraw();
    });
});
    var manageTable;
    var base_url = "<?php echo base_url(); ?>";
    $('#putselectidhere').on('change', function (e) {

  //  $("#abc").css("display","block");

    manageTable = $('#puttableidhere').dataTable( {

        'order': [], 
        'bAutoWidth': false,
        'bProcessing': true,
        'bLengthChange': false, // Remove the show list drop down button
        'bInfo': false,         // Remove info part under the table
         'bFilter' : false,      // Remove search box
        'bDestroy': true,       // Remove table & recreate table
        'bServerSide': false,
        'sAjaxSource': base_url + 'controller/controllerfunction',

        'fnServerData': function (url, data, callback) {
            // Add new data 
            data.push({'name':'putselectidhere', 'value':$('#putselectidhere').val()});
            $.ajax({
                'url': url,
                'data': data,
                'type': 'POST',
                'success': callback,
                'dataType': 'json',
                'cache': true
            });
        },
});         







    });