New User - Show [...] Entries on three lines ..

New User - Show [...] Entries on three lines ..

RadiosRadios Posts: 3Questions: 1Answers: 0

I am a new user and so far I really find this plugin easy and great..

Only real issue I have is that the Show {25, 50, 100, "ALL"} Entries is actually on three lines instead of one.

Now, the table I am adapting does have columns specified as specific widths and I expect that the problem is that this information is in Column 1 which is not wide enough and the data does not span n columns.

How does one correct this ?

<table id="xyz_subscribers" class="display" width="100%">
<thead>
<tr class="unhideACT">
    <th class="rTable" style="width: 6%">  
        <font size="2">Radio Id</font>
    </th>
    <th class="rTable" style="width: 20%" align="left"> 
        <font size="2">Radio Alias</font>
    </th>
    <th class="rTable" style="width: 12%" align="left">  
        <font size="2">Entered</font>
    </th>.
         ........................

Answers

  • kthorngrenkthorngren Posts: 20,141Questions: 26Answers: 4,736

    I don't think the table column width has an affect on the page length menu. See this example:
    https://datatables.net/extensions/select/examples/initialisation/checkbox.html

    Your page length menu looks a bit different than the default Datatables. The dom option could have an affect on this. Or it could be some other CSS issue. Please provide a link to your page or a test case replicating the issue so we can help debug.
    https://datatables.net/manual/tech-notes/10#How-to-provide-a-test-case

    Kevin

  • RadiosRadios Posts: 3Questions: 1Answers: 0

    Okay -- Going to have to put a test case to together -- The code is running inside of Genesis / Enterprise Theme.. The HTML for the Table comes out of a php script and is not something I can post..

    Is there an Easy way to get the Tables with a page length of 50 and drop the ability to change the Page length ? "Show [] Entries"

    In the Header Scripts for the page I currently have --

    <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.19/css/jquery.dataTables.min.css">
    <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/buttons/1.5.6/css/buttons.dataTables.min.css">
    <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
    <script src="//cdnjs.cloudflare.com/ajax/libs/jquery-scrollTo/2.1.2/jquery.scrollTo.min.js"></script>
    <script src="//code.jquery.com/jquery-3.3.1.js"></script>
    <script src="//cdn.datatables.net/1.10.19/js/jquery.dataTables.min.js"></script>
    <script>
    jQuery(function($) {
        $(".dapage-jump").click(function() {
                var where = "#" + $("#field1").val();
                $.scrollTo(where); 
                     });
        $("#field1").on("keyup", function(event) {
            if(event.which==13) {
            var where = "#" + $("#field1").val();
            $.scrollTo(where); 
          }
         });
        $(document).ready(function() {
          $('#xyz_subscribers').DataTable( {
                    "paging":   true,
                    "pageLength": 50
          });
        });
    });
    </script>
    
  • kthorngrenkthorngren Posts: 20,141Questions: 26Answers: 4,736

    You can use the lengthChange option to remove the page length option.

    Kevin

  • RadiosRadios Posts: 3Questions: 1Answers: 0

    THANK YOU !!! Just Found That ! An it works perfectly for this --

    Last question, I have one row of data that is sorting to the buttom based on it's value. But while it's not a header I would like it at the TOP of the LIST not the button. Any Ideas how this might e accomplished.?

  • kthorngrenkthorngren Posts: 20,141Questions: 26Answers: 4,736

    See if the solution in the Sorting with absolute positioned data blog does what you want.

    Kevin

This discussion has been closed.