• Resolved maaper

    (@maaper)


    Hello again,
    I have two different question on how to deal with data representation.

    1. When created tables from existing data source, I need to maintain the line breaks that I have in my original source. How can I solve that with your plugin?
    In my actual plugin, I link the table to the source and if the source has any line break it is replicated on the web.
    That is very important to control the line break, otherwise the table could be very long and it scrolls even on the laptop that is something that I want to avoid.

    2. I also didn’t found any option to control from the backend how to fix the maximum width of any column, is that possible to do in somehow.

    Thanks again for your help.

    • This topic was modified 4 years, 3 months ago by maaper.
Viewing 1 replies (of 1 total)
  • Plugin Author wpDataTables

    (@wpdatatables)

    Hi maaper,

    Sorry for trouble,

    1.) If you what to break long text in your columns in your Excel file you can insert HTML break tag where you need it like this <br>

    "Lorem ipsum dolor sit amet, consectetur adipiscing elit. In in tristique massa.<br> Fusce dapibus dolor sed ipsum blandit, 
    et venenatis turpis placerat.<br> Cras suscipit congue orci, ut iaculis lacus aliquam aliquet.<br> Aenean diam neque, rhoncus 
    at aliquam vitae, luctus vel ligula. <br>Nam magna quam, varius cursus nisi non, ullamcorper commodo dolor. Maecenas 
    nec libero quis neque consectetur dignissim.<br> Donec ex dolor, faucibus feugiat nulla at, luctus congue ligula. <br>
    Phasellus vitae bibendum urna"

    For table with you have option “Limit table width, Word wrap and Column Widthh”. You can read more about this on this link

    At the moment we don’t have an option for max table width, but you can achieve that with CSS:

    1) for table wrapper

    .wpDataTablesWrapper  {
        max-width: 1000px !important;
        margin: 0 auto;
    }

    2) only for table

    .wpDataTablesWrapper table.wpDataTable {
        max-width: 1000px !important;
    }

    Add this code in Custom wpDataTables CSS under the “Custom JS AND CSS” in main settings of wpdatatables.

    This will be affected on all tables, but if you want just for specific one then insert this code on page where is that table between the style tag.(<style>Code here</style>)

    Best regards

Viewing 1 replies (of 1 total)
  • The topic ‘Line breaks on cell’ is closed to new replies.