Topic: Tables in Admin Pack are broken

ilya premium asked 3 years ago


Data tables in the admin pack are broken in my browser:

https://mdbootstrap.com/previews/templates/admin-dashboard/html/tables/datatables.html

  • 'show entries' is in the middle of nowhere (what is it for?)
  • the search field is broken: the label does not resolve properly

Marcin Luczak staff commented 3 years ago

Hi @ilya,

You are facing an issue with the code from the example locally or on our site? Can you provide an image of the issue you are facing? I cannot reproduce your bug using the Firefox browser looking at our site. Also please send errors/warnings from the browser dev tools, if any. 'Show entries' serves to indicate how many elements are to be displayed on the table page.

Regards, Marcin


Marcin Luczak staff answered 3 years ago


Thank you for this instruction, I can see what is wrong now. According to the example given in our documentation for Datatables, please wrap the whole JavaScript code with:

$(document).ready(function () {
    ... scripts from the example
});

This should fix your problem. This is a general recommendation as sometimes custom scripts may be invoked before other javascript imports, causing your code renders incorrectly.

Regards, Marcin


ilya premium answered 3 years ago


Hi Marcin,

steps to reproduce: Please

  • download the admin template pack from gitlab
  • unzip it
  • open html/tables/datatables.html

That is what I am getting:

md table



Please insert min. 20 characters.

FREE CONSULTATION

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

Status

Answered

Specification of the issue

  • ForumUser: Premium
  • Premium support: Yes
  • Technology: MDB jQuery
  • MDB Version: 4.18.0
  • Device: laptop
  • Browser: Firefox
  • OS: Ubuntu 18.04
  • Provided sample code: No
  • Provided link: Yes