[wp-hackers] Twenty Ten theme issue?

Otto otto at ottodestruct.com
Mon Aug 16 07:27:09 UTC 2010


On Mon, Aug 16, 2010 at 2:07 AM, Ryan Hellyer <ryan at pixopoint.com> wrote:
>> No, it sounds like a WordPress bug. Resizing should not be done via
>> the image width and height tags, ever.
>
> This is true, but the theme should not be forcibly over-riding the
> HTML like that either, particularly since WordPress actually has
> functionality in the back-end for actually changing those dimensions
> without even touching the code.

Well, my point is that if WP was doing the right thing here and using
inline styles, then it wouldn't matter what the theme did. Inline
styles always win.

The main purpose of a theme's stylesheet is pretty much to "override"
the HTML. Stylesheets control the presentation, after all. In this
case, the height and width of "auto" is merely expressing the default
settings, and normally it'd be the correct way to do it.

Short term fix: remove those.
Long term fix: Change WP to not use width and height attributes for
resizing, but to use inline styles instead.

-Otto


More information about the wp-hackers mailing list