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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T16:41:35+00:00 2026-05-20T16:41:35+00:00

This may seem like a blast from the past but due to project constraints

  • 0

This may seem like a blast from the past but due to project constraints I am stuck with quirks mode and tables…

The tables that i’m dealing with have a single image in each cell where all the cells should be the same size. The tables width and height are set as percentages of a parent container.

The problem is the images don’t resize down, they stay at their original size seemingly no matter what I do. Then the table doesn’t adhere to its set size, it has resized to hold all of the images. In standards mode I believe ‘width: 100%’ on the image gets closer to what I want to achieve.

I’m considering a javascript solution which loops over each image calculating what their size should be and resizing manually. But this is probably going to cause a bit of a loading time at the start which isn’t ideal.

Edit:

I have written a basic example at JSBin. What I want to achieve is to be able to set the size of the table and have the images resize, whether growing or shrinking to their cell.

The 4th jsbin revision uses the dummy images.

  • 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-20T16:41:36+00:00Added an answer on May 20, 2026 at 4:41 pm

    I think I’ve solved this.

    I’ve tested this demo in Chrome, Firefox, Internet Explorer, Safari, Opera; they all render consistently.

    • I had to add a wrapper div in each cell. I know this isn’t awesome, but it had to be done to make it work in Chrome.
    • I added table-layout: fixed to make it work in Internet Explorer.

    Live Demo

    CSS:

    #mycontainer {
        width: 300px;
        height: 300px;
        border: 1px solid red;
    }
    #mytable {
        height: 50%;
        width: 50%;
        table-layout: fixed;
    }
    #mytable div {
        width: 100%;
        height: 100%;
    }
    #mytable img {
        width: 100%;
        height: 100%;
    }
    

    HTML:

    <div id="mycontainer">
        <table id="mytable" cellpadding="0" cellspacing="0">
            <tr>
                <td><div><img src="http://dummyimage.com/28x28/000/fff.png&text=Dummy" /></div></td>
                ...
            </tr>
            ...
        </table>
    </div>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This may seem like a simple question but i am getting an error when
This may seem like a stupid question, but what message do i send to
This may seem like a silly question but I can't figure it out. let's
This may seem like a realy basic question but... How do you use double
This may seem like an odd question but I was talking to a friend
Hi this may seem like a weird question, but here's my situation: I have
Now this may seem like a silly question, but I need to know how
I know this may seem like a math question but i just saw this
This problem may seem like school work, but it isn't. At best it is
This may seem like a simple question, but I can't find the answer anywhere

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.