Gencaydo free asked 4 years ago


Hi Friends,

I Tried MDB basic examples with my project. My project MVC 5.0 and ı have already install bootstrap package but I have a issue about basic Data Table. I cant see search box or another opitons, just table and data. I have already linked all css and js files. you can see my code and whats happen in table format

Material Design for Bootstrap

<!-- Start your project here-->
<div style="height: 100vh">
    <div class="flex-center flex-column">
        <table id="dtBasicExample" class="table table-striped table-bordered" cellspacing="0" width="100%">
            <thead>
                <tr>
                    <th class="th-sm">
                        Name
                    </th>
                    <th class="th-sm">
                        Position
                    </th>
                    <th class="th-sm">
                        Office
                    </th>
                    <th class="th-sm">
                        Age
                    </th>
                    <th class="th-sm">
                        Start date
                    </th>
                    <th class="th-sm">
                        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>
        </table>
</div>

$(document).ready(function () { $('#dtBasicExample').DataTable(); $('.dataTables_length').addClass('bs-select'); });


Grzegorz Bujański staff commented 4 years ago

Hi.

You need import datatables css and js. Did you add this: <script type="text/javascript" src="js/addons/datatables.min.js"></script> and this: <link href="css/addons/datatables.min.css" rel="stylesheet"> in Your project?

Best, Grzegorz



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Opened

Specification of the issue

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB jQuery
  • MDB Version: 4.12.0
  • Device: Toshiba Satellite
  • Browser: Chrome
  • OS: Wİndows 10
  • Provided sample code: No
  • Provided link: No
Tags