Data Tables

Data tables organize and display information in a structured manner, allowing for easy sorting, filtering, and analysis. They support efficient data management and clear presentation.
DataTables is a powerful jQuery plugin used to enhance HTML tables with features like pagination, filtering, and sorting. Here's a basic guide to getting started with DataTables:

Step 1: Include DataTables CSS and JS files

You need to include the DataTables CSS and JavaScript files in your HTML file. You can use the following CDN links:
				
					
<!-- DataTables CSS -->
<link rel="stylesheet" href="https://cdn.datatables.net/1.11.5/css/jquery.dataTables.min.css">
				
			
				
					<!-- jQuery -->
    <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
    <!-- DataTables JS -->
    <script src="https://cdn.datatables.net/1.11.5/js/jquery.dataTables.min.js"></script>
				
			

Step 2: Create an HTML table

Create a table in your HTML file. Ensure your table has a header and 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>
        <!-- Add more rows as needed -->
    </tbody>
</table>

				
			

Step 3: Initialize DataTables

Once your table is set up, you need to initialize DataTables using jQuery:
				
					<script>
    $(document).ready(function() {
        $('#example').DataTable();
    });
</script>

				
			

Assessment

ID Status Date Room External Room Id Age Group Staff Assessor Agency Phase Cycle Type Actions

Design

Picture of Abel Ferro
Abel Ferro

Twinkle System Designer

CDN

Picture of Raul Suarez
Raul Suarez

DevOps Engineer

Scroll to Top