Image sizing within a table cell
-
Hi,
I’m trying to specify the size of an image in a table cell. No matter what I do, the image is always square, though I want a landscape-style sizing.
This is the img HTML I have in the table cell.
<img src="https://www.greenneedham.org/blog/wp-content/uploads/2021/11/Tesla-Model-3-mjg-150x150.jpg" alt="" width="113" height="75" class="wp-image-14211" />
When I inspect the image in the browser, I see this in the code:
element.style {
}
.tablepress img {
margin: 0;
padding: 0;
border: none;
max-width: none;
}
.entry-content img, .comment-content img, .widget img {
max-width: 100%;
}
img {
max-width: 100%;
height: auto;
vertical-align: top;
margin-bottom: 18px;
}
html :where(img[class*=wp-image-]) {
height: auto;
max-width: 100%;
}
* {
box-sizing: border-box;
}
img[Attributes Style] {
width: 113px;
aspect-ratio: auto 113 / 75;
height: 75px;
}Is there a way to override this?
Thanks!
- The topic ‘Image sizing within a table cell’ is closed to new replies.