Hey there, Awesome Customers!

Just a heads up: We'll be taking a breather to celebrate International Workers' Day (May 1st and 2nd - Wednesday and Thursday) and Orthodox Easter from Good Friday (May 3rd) through Easter Monday (May 6th). So, from May 1st to May 6th, our team will be off enjoying some well-deserved downtime.

During this time, our customer support will be running on a smaller crew, but don't worry! We'll still be around to help with any urgent matters, though it might take us a bit longer than usual to get back to you.

We'll be back in action at full throttle on May 7th (Tuesday), ready to tackle your questions and requests with gusto!

In the meantime, you can explore our documentation for Amelia and wpDataTables. You'll find loads of helpful resources, including articles and handy video tutorials on YouTube (Amelia's YouTube Channel and wpDataTables' YouTube Channel). These gems might just have the answers you're looking for while we're kicking back.

Thanks a bunch for your understanding and support!

Catch you on the flip side!

Warm regards,

TMS

Okay
  Public Ticket #2385141
Column width
Closed

Comments

  • Eufemia Scarfone started the conversation

    I have gone through all the general and specific styling settings, but I haven't found an answer. I have a very wide table. It looks really ugly when I use the general settings for word wrap and limit table width. It also stretched the buttons into weird shapes and in some cases the whole button is not visible in the table. 
    What I want to do:

    I have several columns that I know will never be larger than 2 or 5 characters, for example. Is there a way to limit the size of only those columns? I also would need the column headers for these columns to wrap. 
    I don't see a way to set that per column. Am I missing something? Including a screenshot of my table so you can see what I mean. The year, and age columns will always be smaller than everything else. 

  •  2,498
    Aleksandar replied

    Hello Eufemia

    When you enable "Limit Table Width", every column gets a new option:

    6734610835.png

    If you enter the data like shown above, it will be considered as 100px, but you can also use %, so 25% would make that column take 25% width of the page.

    To wrap words in the header, you would need to add custom CSS in wpDataTables settings/Custom JS and CSS/Custom CSS field:

    table.wpDataTable th { white-space: normal !important; }
    

    Kind Regards, 

    Aleksandar Vuković
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables