Support » Theme: Twenty Eleven » Character Encoding error when validating my site.

  • Resolved square_eyes

    (@square_eyes)


    Character Encoding error when validating my site.

    The character encoding specified in the HTTP header (utf-8) is different from the value in the <meta> element ( utf-8)

    Where is the encoding sourced from in the theme?

    I have found

    <meta charset="
    <?php bloginfo( 'charset' ); ?>
    " />

    But where does this come from? Somewhere there is an extra space being added.

    Many thanks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Siobhan Bamber (siobhyb)

    (@siobhyb)

    Automattic Happiness Engineer

    Can you double-check that the snippet you found is all on one line, with no space between the first quotation and the starting PHP declaration. As follows:

    <meta charset="<?php bloginfo( 'charset' ); ?>" />

    OK that was it. Seems so simple now. But I really just copied what was in the modified theme file. My partner or I may have inadvertently split that line.

    Sometimes code validators/beautifiers split out lines and I don’t know when to accept or reject the changes:)

    In any case, I can see what was wrong and fixed it. Thanks!

    Siobhan Bamber (siobhyb)

    (@siobhyb)

    Automattic Happiness Engineer

    Ah, the simple things always seem to cause the most frustration. 🙂 Glad you’ve fixed it now. 🙂

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Character Encoding error when validating my site.’ is closed to new replies.