🔒 Closed Data table

Status
Not open for further replies.

Netflix

Forum Veteran
How to use datatables for php?
I have read the documentations but still not getting the results..
Using the latest default files..
Code:
<!DOCTYPE html>
<html>
<head>
    <title></title>
<link rel="stylesheet" type="text/css" href="DataTables-1.10.18/css/jquery.dataTables.css"/>
 
<script type="text/javascript" src="DataTables-1.10.18/js/jquery.dataTables.js"></script>
<script type="text/javascript" src="jquery.js"></script>
</head>
<body>
<table id="example" class="display" style="width:100%">
        <thead>
            <tr>
                <th>Name</th>
                <th>Position</th>
                <th>Office</th>
                <th>Age</th>
                <th>Start date</th>
                <th>Salary</th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td>Tiger Nixon</td>
                <td>System Architect</td>
                <td>Edinburgh</td>
                <td>61</td>
                <td>2011/04/25</td>
                <td>$320,800</td>
            </tr>
            
            
        </tbody>
        <tfoot>
            <tr>
                <th>Name</th>
                <th>Position</th>
                <th>Office</th>
                <th>Age</th>
                <th>Start date</th>
                <th>Salary</th>
            </tr>
        </tfoot>
    </table>
</body>
<script>
    $(document).ready(function() {
    $('#example').DataTable();
} );
</script>
</html>
 
Dapat laging nasa taas yung jquery above all other scripts, nandyan kasi yung mga declarations na kailangan ng datatables para sa initialization
 
Status
Not open for further replies.

About this Thread

  • 2
    Replies
  • 419
    Views
  • 3
    Participants
Last reply from:
nogats07

Trending Topics

Online now

Members online
1,333
Guests online
3,386
Total visitors
4,719

Forum statistics

Threads
2,305,879
Posts
29,168,309
Members
1,195,477
Latest member
Jomar Gabriel
Back
Top