2

I am already searched this issue over internet, I have also used their examples too but It did not work on mine. I have datatables with zero configuration setting, what I want to achieve is that I want the column to be auto adjusted based in the contents on the column.

here's my code.

    <script type="text/javascript" language="javascript" class="init">

        $(document).ready(function() {
            $('#example').dataTable(
            "bAutoWidth":false
            );
        } );

    </script>

I have also tried to adjust using the tables but it did not work.

<table id="example" class="display" cellspacing="0" width="100%">

1 Answer 1

3

Have you tried this in table cell width:auto; ?

Sign up to request clarification or add additional context in comments.

2 Comments

its css style to be added to the element and not class attribute. Hope this helps
@JaysonLacson style="width:auto;"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.