Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1081029
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T22:06:52+00:00 2026-05-16T22:06:52+00:00

I am trying to fix a horrid nested table layout for a site. The

  • 0

I am trying to fix a horrid nested table layout for a site. The page will have a variable number of elements that leverage Google charts. Instead of complex spaghetti code that tries to lay things out inside of table cells I want to use a horizontal UL so the content blocks will lay out cleanly regardless of the charts involved. The problem I am having is the Google charts components leverage tables. When a table element exists anywhere inside a LI the LI gets moved to the next line (assuming because table elements by default have a newline before and after).

I have tried the various display modes for the table with no luck. Is this a lost cause?

Example HTML code to illustrate the issue:

<html>
<body>
<style type='text/css'>
 #navlist li{
    display:inline;
    list-style-type:none;

    }
</style>
    <ul id='navlist'>
        <li>TEST</li>
        <li>TEST2</li>
        <li>
            <table style='border:1px solid black'><tr><td>TEST</td></tr></table>
        </li>
        <li>TEST3</li>
        <li>
            <table style='border:1px solid blue'><tr><td>TEST</td></tr></table>
        </li>
        <li>
            <table style='border:1px solid green'><tr><td>TEST</td></tr></table>
        </li>
    </ul>
</body>
</html>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T22:06:52+00:00Added an answer on May 16, 2026 at 10:06 pm

    Set display: inline-block; on your LI elements; that should do it nicely. It doesn’t really work in Firefox 2, but nobody uses Firefox 2 anymore. You’ll need to specify a doctype to get it to work in IE.

    <!DOCTYPE html>
    <html>
      <head>
        <style type='text/css'>
          #navlist li {
            display: inline-block;
            zoom: 1;
            *display: inline;
            list-style-type: none;
            vertical-align: middle;
          }
        </style>
      </head>
      <body>
        <ul id='navlist'>
          <li>TEST</li>
          <li>TEST2</li>
          <li>
            <table style='border:1px solid black'><tr><td>TEST</td></tr></table>
          </li>
          <li>TEST3</li>
          <li>
            <table style='border:1px solid blue'><tr><td>TEST</td></tr></table>
          </li>
          <li>
            <table style='border:1px solid green'><tr><td>TEST</td></tr></table>
          </li>
        </ul>
      </body>
    </html>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just have a problem that I have been trying to fix for the
I am trying to fix an error for a friend in his site that
I am trying to fix a web site. It opens a help page in
i am trying to fix a site I am helping a friend with, and
trying to fix a CSS bug for some code that someone else wrote. I'm
Im trying to fix a bug that only appears in internet explorer 6. The
I'm trying to fix an existing C-program with VS2005 that eventually calls int system(command)
I'm trying to fix my code but I have no idea why I'm getting
While trying to fix the hover bug in internet explorer I realised that the
I'm trying to fix a .hta that someone at my company created 3 or

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.