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 8464181
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T14:39:50+00:00 2026-06-10T14:39:50+00:00

Throughout my website, I have many <table> s in which there is a specific

  • 0

Throughout my website, I have many <table>s in which there is a specific column we want to have squeezed to it’s minimum possible space (without having it’s text wrapped). Other sibling cells share the rest of the space automatically.

I’m using the following trick and it works in all browsers except IE7-. (At this time I actually only care about IE7)

table {width:100%;}
table td.min-col {white-space:nowrap; width:1px; }

jsFiddle link: http://jsfiddle.net/vm8gc/23/

If you try this in IE7 you will notice it acts differently (not expected behavious). — see screen capture below.

Can anyone think of a fix for IE7 to achieve this?


Attachments:

All other browsers:

enter image description here

IE7:

enter image description here

  • 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-06-10T14:39:52+00:00Added an answer on June 10, 2026 at 2:39 pm

    CSS 2 Version

    For some reason Internet Explorer seems to ignore white-space on TDs. Best way around the problem is to use a span inside the TD.

    <td><span style="white-space: nowrap;">This should not wrap</span></td>
    

    As usual IE doing it’s own thing 😉

    For info on white-space support, see here:

    http://www.quirksmode.org/css/whitespace.html

    PRE Version

    An alternative which would have better support with older browsers would be to do the following:

    <td><pre>This will not wrap</pre></td>
    

    And then have your pre element set-up to either be styled in the same way as your normal text or enable it to inherit style from it’s parents (inheriting probably has less support that just specifiying the style):

    td pre { font-family: inherit; font-size: inherit; color: inherit; ... }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Lets say I have multiple DataGrids throughout my winform app and I want to
I have an ASP.Net 4.0 website which uses SQL Server CE and EF code-first
I have a job that requires a lot of tedious clicking throughout a website
I have a whole bunch of HTML code throughout pages on my website and
I have been asked to change the font throughout a website into Gil Sans
while programming throughout the years I have never posted a question on this website,
I have a table that has a about 15 different fields, some of which
Here is my situation. I have some links throughout a website. Some of them
in Visual Studio 2010 I have a really big ASP.NET website project which has
I've made a footer element that will be shown throughout my entire website. The

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.