Support » Fixing WordPress » Formatting nested tables in HTML

  • I am porting an html site to WP and have carried over the code and updated the stylesheet of the TwentyTen template, but the spacing is off in one table and I can’t seem to fix it. Please help!

    The site is:

    See the Get Quote column.

    Please let me know if you would like to see the code, I assume you can preview with view pagesource.

    Thank you! Gary

Viewing 3 replies - 1 through 3 (of 3 total)
  • You have an extra empty set of p tags in that cell — between the javascript and the enclosed table — that’s part of the problem.

    But aside from that, table layouts are really outdated and you’re likely to have a lot of problems trying to make that approach work with WP. I know it’s a lot of work to totally convert to a CSS based layout, but in the long run, it will be worth your while. Your tables are also using a lot of deprecated inline CSS code — again a huge problem in terms of maintaining the site and long-term functionality.

    You also have some major errors with the title and body tags — so the validator won’t even finish validating the page:

    No matter what, fix those and then see what other errors you really need to fix.

    One other REALLY major thing is that you absolutely need to be using a Child Theme — as is, all your changes to the theme files, including the CSS, will be lost when WP is updated.

    First of all, I am startled to see there are still table-based layouts being used. But who am I to lecture.
    I am not sure what part of the spacing want to change? Is it the spacing between things like “Your name” and the input box? If so you need the following CSS:
    #frmQuote p { margin: 0; }
    Edit: I agree with WPyogi

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Formatting nested tables in HTML’ is closed to new replies.