[Resolved] Table customization

Home Forums Support [Resolved] Table customization

Home Forums Support Table customization

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #262595
    Eric

    Hi Tom, all,
    I would like to customized the table properties (margin, border line colors…).
    GP doesn’t include a way to do it? Is the “Add CSS” setting the only/straighter way to do that or have I missed something?
    Also, I would like to change the space before/after my headings in the sidebar. How can I do that?
    Thanks a lot
    Eric

    #262601
    Leo
    Staff
    Customer Support

    Hi Eric,

    I would suggest using a plugin for creating tables. Here are a couple suggestions from Tom and another other user suggested:
    https://en-ca.wordpress.org/plugins/magic-liquidizer-responsive-table/ (responsive)
    https://wordpress.org/plugins/tablepress/

    #262912
    Eric

    Thank you Leo. Your links may help me some day, but unless I have missed something they don’t allow me to change the border colours and margins for example.
    Does GP includes this somewhere in its configuration? (if not, I’ll have to add the CSS properties by myself)
    Thanks
    Eric

    #262971
    Leo
    Staff
    Customer Support

    Hi Eric,

    Unfortunately GP does not currently support table customization.

    I would still recommend using a plugin as it would be responsive (unless you want to write your own codes to make it responsive), and you should still be able to write CSS to modify the border margin etc for the plug in.

    Hope this helps.

    #263115
    Eric

    Yes it does.
    Thanks a lot Leo.
    Best,
    Eric

    #263144
    Leo
    Staff
    Customer Support

    Glad I can help!

    #1186867
    Hafsa

    Does GP still not submit table customization?

    #1187101
    David
    Staff
    Customer Support

    Hi there,

    if you require Tables in your site you’re better off using a plugin that provides responsive ands styling controls.

    #1582651
    Michael

    Just looking at tables on my site.

    Am I right that GP sets a thin border on tables as default?
    https://github.com/tomusborne/generatepress/blob/master/assets/css/main.css#L190

    I think this means that the old-style table attributes don’t work. So, for example, <table border="0"> has no effect as it is overriden and I get a thin light border showing.

    Does this mean I have to use CSS? I am working on migrating a large site which has many different tables with many varied presentations set with old-style table attributes. Some have borders, some don’t. They’re proper tables showing tabulated data, so I don’t want to revisit each one and apply inline CSS, and a global CSS rule to set border=”0″ will presumably also override the table setting.

    Just wondering what the thinking is behind making tables have a border when the advice seems to be that GP doesn’t do tables.

    Any tips appreciated.

    #1583107
    David
    Staff
    Customer Support

    Hi there,

    not sure if this will work but you can try overwriting the properties with initial
    e.g

    table,
    th,
    td {
    	border: initial;
    }

    GP + GPP is almost 7 years old now – some of the CSS for things such as tables were standard boiler plate CSS for themes back then, and for backwards compatibility it cannot be easily changed. To be honest i am not sure i have ever seen this come up before.

    #1584525
    Michael

    Thanks – super useful as I didn’t know about the ‘initial’ setting.

    The site I’m converting has been running for more than 20 years and has thousands of pages of hand-crafted HTML. It’s quite a challenge to bring it all up-to-date!

    #1584547
    David
    Staff
    Customer Support

    Wow – i bet thats a fun job.
    Let us know if that initial setting works – haven’t tested ….

    #1585481
    Michael

    It is!
    Yes, that initial setting seems to be doing a good job.
    thanks!

    #1585513
    David
    Staff
    Customer Support

    Awesome ! Glad to hear that

Viewing 14 posts - 1 through 14 (of 14 total)
  • You must be logged in to reply to this topic.