Laravel页面中未加载默认表格样式

时间:2019-06-03 15:56:50

标签: javascript php

我的laravel项目中未加载默认表格样式

我正在使用laravel并且dataTables.net的默认表样式不起作用

<!DOCTYPE html>
<html>
<head>
    <title>Datatables Server Side Processing in Laravel</title>
    <!--Data Tables.net-->
    <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.19/css/jquery.dataTables.min.css">


    <script type="text/javascript" charset="utf8" src="https://cdn.datatables.net/1.10.19/js/jquery.dataTables.min.js"></script>



     <!--CDN J-Query-->
    <script
        src="https://code.jquery.com/jquery-3.4.1.min.js"
        integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo="
        crossorigin="anonymous">
    </script>

    <script>
        $(document).ready( function () {
        $('#myTable').DataTable({
            "searching": true
        });

        } );
    </script>

</head>
<body>
    <br />
    <h3 align="center">Datatables Server Side Processing in Laravel</h3>
    <br />
    <table id="myTable" class="table border">
        <thead>
            <tr>
                <th><strong>State Name</strong></th>
                <th><strong>PC Name</strong></th>
                <th><strong>Winning Party</strong></th>
                <th><strong>Total Marks</strong></th>
                <th><strong>Rank</strong></th>

            </tr>
        </thead>
        <tbody>

            <!@foreach($lok2014all as $winner)
            <tr>
                <td>{{ $winner->statename}}</td>
                <td>{{ $winner->pcname}}</td>
                <td>{{ $winner->party}}</td>
                <td>{{ $winner->total}}</td>
                <td>{{ $winner->rank}}</td>

             </tr>
                @endforeach
        </tbody>
    </table>

</body>
</html>

该表没有任何样式。没有分页链接,没有搜索框没有显示条目。我的表格没有边框/格式

0 个答案:

没有答案