Grow your CSS skills. Land your dream job.

Problems on webkit browsers

  • # May 10, 2009 at 1:02 am

    Heya all,

    Gotta say, this is my first post on a website that has been absolutely invaluable to me. Chris, I credit you with single-handedly teaching me CSS. Thank you much for your efforts.

    I’ve run in to a bit of a snag that I can’t figure out. It’s likely something obvious.

    I’ve got a site I’m working on… http://www.freshbreadmedia.com/2

    It looks great on ff and explorer, but on webkit browsers (safari and chrome) the main background does not display. I’d include the whole css file if needed, let me know. I have no idea where to begin looking for a fix.

    Thanks in advance,
    Chris

    # May 10, 2009 at 3:24 pm

    Remove this line from your stylesheet:

    Code:
    @charset “UTF-8″;
    # May 12, 2009 at 7:33 am

    Thank you so much! Don’t know where I picked that up from, but it’s gone now and works perfectly! Thanks!

    # May 12, 2009 at 7:50 am

    That must be because of Dreamweaver, when creating a new CSS file it automatically fills the first line with that charset thing. But what does it actually do? And why the @? Doesnt that mean that the output after the @ is ignored?

    # May 12, 2009 at 8:28 am

    Dreamweaver puts it there for the same reason it is in your html pages. It tells the browser how to interpret the characters on the page. As far as I am aware, all of the main browsers default to using whatever charset is specified in the html for the stylesheets as well. It shouldn’t do any harm to the page but it must be the very first thing on the stylesheet before any comments or style rules. It seems that the web-kit browsers don’t like it and I confess I never ever use it.

    # May 12, 2009 at 11:40 am

    That’s very good to know. I’ve never heard of/seen it in my DW. I guess it happens when you have DW create your CSS file for you.

    # May 12, 2009 at 4:54 pm

    That’s good to know, apostrophe. I always delete it when I come across it in style sheets, but I never knew it to pose a problem. Hmm…silly DW…

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".