Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/codeigniter/3.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
jQuery表排序器不能与CodeIgniter一起使用_Codeigniter_Jquery Plugins - Fatal编程技术网

jQuery表排序器不能与CodeIgniter一起使用

jQuery表排序器不能与CodeIgniter一起使用,codeigniter,jquery-plugins,Codeigniter,Jquery Plugins,我下载了,它可以正常工作,但如果我在codeigniter中使用,firebug会在下拉列表中选择不同的值时说c未定义 我移动视图/模板/标题/ header.php 我只对表格行进行了硬编码,并用span替换了img,但它对我有效:你在CodeIgniter上试用过吗?我用spans替换了img,但仍然存在相同的问题…只是通过CI尝试了一下,效果很好,下面是我的输出: <!-- Tablesorter --> <?php echo link_tag('tableso

我下载了,它可以正常工作,但如果我在codeigniter中使用,firebug会在下拉列表中选择不同的值时说
c未定义

我移动视图/模板/标题/

header.php



我只对表格行进行了硬编码,并用
span
替换了
img
,但它对我有效:你在CodeIgniter上试用过吗?我用spans替换了img,但仍然存在相同的问题…只是通过CI尝试了一下,效果很好,下面是我的输出:
<!-- Tablesorter -->
    <?php echo link_tag('tablesorter/themes/blue/style.css');?>
    <script type="text/javascript" src="<?php echo base_url(); ?>tablesorter/js/jquery.tablesorter.js"></script>
    <script type="text/javascript" src="<?php echo base_url(); ?>tablesorter/js/jquery.tablesorter.pager.js"></script>
    <script type="text/javascript">
    $(function() {
        $("table")
            .tablesorter({widthFixed: true, widgets: ['zebra']})
            .tablesorterPager({container: $("#pager")});
    });
    </script>
    <!--// Tablesorter -->
<table cellspacing="1" class="tablesorter">
            <thead>
                <tr>
                    <th>Country Name</th>
                    <th>Action</th>
                </tr>
            </thead>
            <tfoot>
                <tr>
                    <th>Country Name</th>
                    <th>Action</th>
                </tr>
            </tfoot>
            <tbody>
                <?php foreach ($countries as $key): ?>
                <tr>
                    <td><?php echo $key['countryName'];?></td>
                    <td><?php echo anchor("countries/edit/".$key['countryId'],"Edit")?></td>
                </tr>
                <?php endforeach; ?>
            </tbody>
        </table>
        <div id="pager" class="pager">
            <form>
                <img src="<?php echo base_url(); ?>tablesorter/icons/first.png" class="first"/> <img src="<?php echo base_url(); ?>tablesorter/icons/prev.png" class="prev"/>
                <input type="text" class="pagedisplay"/>
                <img src="<?php echo base_url(); ?>tablesorter/icons/next.png" class="next"/> <img src="<?php echo base_url(); ?>tablesorter/icons/last.png" class="last"/>
                <select class="pagesize">
                    <option selected="selected"  value="10">10</option>
                    <option value="20">20</option>
                    <option value="30">30</option>
                    <option  value="40">40</option>
                </select>
            </form>
        </div>