[wp-hackers] Inline styles and TinyMCE

Otto otto at ottodestruct.com
Thu Sep 10 17:39:37 UTC 2009


I like the idea, but the execution would be painful. Every time we try
to standardize something in this way, we end up having lots of
backward compatibility for several versions, in order to get
theme/plugin devs the time to fix their stuff. And then we still end
up breaking things.

In going forward, lets keep this sort of thing in mind, and make
everything start with something obvious, like wp- for classes and
such.

But the ones we've already got let's just leave alone, for now.
Changing them will break sites. Adding new ones to replace them just
adds worthless cruft that never gets cleaned up properly, and still
will break sites.

-Otto
Sent from Memphis, TN, United States


On Thu, Sep 10, 2009 at 10:15 AM, Jess Planck <jess at funroe.net> wrote:
> I made a comment to that ticket, but I thought I would make it here as well.
>
> It's a great idea, but before it gets set in stone I would really like to
> see some better CSS naming conventions for the HTML objects WordPress
> creates. There is no coding standard for CSS like there is for PHP in
> WordPress, so here's the type of things we get:
>
> For an attachment starting div id is attachment_13 with classes wp-caption
> and alignleft wrapped around an img with classes size-medium wp-image-13 and
> a p with class wp-caption-text. It's not bad but there are dashes,
> underscores, compounded words, and very little to help you predict the sort
> of CSS that WordPress is going to spit out. Of course object oriented CSS
> approaches were the techniques aren't being used. It's getting better, but
> don't go look at the some of the buddypress CSS names (it burns!).
>
> If WordPress adds some removable default css for these objects then some
> better naming conventions for the CSS classes and ids would really help.
> Especially some prefix that says "This came from WordPress" like a
> wp-gallery, wp-attachment, or something else parse-able used in CSS ids and
> classes.


More information about the wp-hackers mailing list