Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS CSS Inline Styles. Hover?

  • This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #24828
    mattvot
    Member

    Just a general question and kinda survey for interest really.

    Is there a way to define hover actions in an inline style?

    If not, should there be?

    #57427
    TheDoc
    Member

    As far as I know, you can’t do it. It would have to go into the <head> at the beginning of the document (close enough I guess).

    Should you be able to? I guess so, if you’re into inline styles (which you shouldn’t be). Everything should go into your CSS document, it’ll come around to bite you in the ass sooner or later if you get lazy and start using inline styles. Using inline styles so essentially just going <font color="red">red font</font>. We don’t want to go back to that now, do we?

    #57454
    Chris Coyier
    Keymaster

    Ditto the Doc. I don’t think it can be done. Interesting question about whether it should be possible or not. Of course we all know that inline styles are not ideal, I still would argue it should be POSSIBLE.

    #57486
    mattvot
    Member

    Yes, We definitely do not want to go back to those days. But I use inline styles allot while developing before I move them to a style sheet, as I spend a lot of time on WordPress themes in the inbuilt theme editor for clients. It mainly saves time I find. So, I would of liked an ability to have inline hover but I have no doubt whatsoever it would not be included in CSS3, CSS4 and so on, based on the fact it is considered a step back.

    #58426
    royler
    Participant

    http://www.nikkifoundation.com/2008/09/ … yle-hover/

    i’ve seen that suggested, but i’m not sure what all the onmouseover business is.

    #58370
    Chris Coyier
    Keymaster

    Ah yeah, that’s JavaScript, I suppose that’s the ticket if you absolutely need a stopgap solution.

Viewing 6 posts - 1 through 6 (of 6 total)
  • The forum ‘CSS’ is closed to new topics and replies.