Okay
  Public Ticket #2610429
Formatting of two images on same page
Closed

Comments

  • Heather Wicksted started the conversation

    Howdy. I have a page that has two tables on it. When I change the display settings on one (specifically, I want it to only be the width of the page and to wrap lines), it adds that to the second table - which should not be limited in width since it's big and needs a scroll bar! 

    I will send you login info and the page URL seperately the page is an admin veiw only. 

    Thanks!

  •   Heather Wicksted replied privately
  •   Aleksandar replied privately
  • Heather Wicksted replied

    Weird...I thought I had posted a reply.... clearly I haven't which explains why I haven't recieved a response! 

    The issue is still occuring... but I think I understand why you see it as not occuring. I have attached some screen shots to see the difference more clearly, and I hope I have explained the issue in a better way. 

    Here is what my ideal end goal is:

    Table 1 SHOULD word wrap and get taller as info is added. 

    Table 1 SHOULD have a scroll bar and have no words wrapped in any columns - thereby staying the same height regardless of the data. 


  •  2,572
    Aleksandar replied

    I see Heather, I see, thanks for that.

    The issue is in our code because the "white-space: normal;" is added with an !important clause to the header and cells in order to override wpdatatables-bootstrap-css.

    So, this is applied to all tables on a page.

    To resolve this, I added the following CSS on the page, in the second table's widget:

    #table_3_wrapper table.wpDataTable td, #table_3_wrapper table.wpDataTable th {
    white-space: nowrap !important;
    }
    

    3659427140.png

    As far as I can see, it's working fine - the first table is wrapped, and limited to the page's width, and the second table isn't wrapped, and it's scrollable. Please check and let me know (don't forget to delete cache).

    Don't be confused by #table_3_wrapper - each table on a page gets an odd number assigned to its object, so if you have 4 tables on a page, they'd be:

    #table_1
    #table_3
    #table_5
    #table_7

    This'll be useful if you need to apply this (or similar) code on other pages. Our developers will work on this in the future, but at the moment this is the only workaround.

    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

  • Heather Wicksted replied

    Amazing! Thanks so much. As always you folks are courteous, professional and helpful. So appreciate it.. 

    Cheers!

    Heather

  •  2,572
    Aleksandar replied

    You're welcome, Heather

    Glad I could be of service.

    If you have any further questions or issues, please feel free to open a new ticket, and we'll gladly help.

    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