How can you provide a minimum width for a TD, which may optionally contain an image? I ask this because I use the Javascript chess widget, but when there are no pieces in any of the squares of a particular column, no matter which td width style is set to 36px, this column is significantly narrower than those that have at least , one line containing an image of a chess piece.
Note that the whole style is set directly in each td cell. I read somewhere that a possible solution would instead be to create a div inside td and set the width. I hope to avoid this, as this may require significant changes to the Javascript core library. I tried to clarify! It is important along with the width, but it did not affect.
Using firebug, I can change the width attribute, but the numbers seem to be wrong. For example, I can reduce the width to 0, and it still looks the same. Or I can set the width to more than 36 and, apparently, increase the width to -36, but if, for example, I set both the height and the width of one of these narrow cells to the same number, say 60 pixels , the height of which is displayed more than the width and displayed as a rectangle, not a square.
In addition, not only td can contain an image, but each square also defines a background image. So I'm at a loss :( Thanks in advance
source
share