WordPress.org

Support

Support » Plugins and Hacks » WP Google Fonts » W3C Validation Error

W3C Validation Error

  • The W3C Validator comes up with the following error:

    Line 11, Column 110: & did not start a character reference. (& probably should have been escaped as &.)

    …pis.com/css?family=Caesar+Dressing:400&subset=latin' type='text/css' media='al…

    I don’t know a lot about PHP, but went into the google-fonts.php file anyways and escaped the ampersand on line 1197 like this:

    $query .= "&subset=" . implode(",", $subsets);

    Still got the same validation error, though.

    chou-seh-fu.com/wordpress/

    http://wordpress.org/extend/plugins/wp-google-fonts/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Sorry, the line I tried to fix should look like this:

    $query .= "& amp;subset=" . implode(",", $subsets);

    (With no space between the & and the amp;)

    Thanks for seeing that JPecsenyicki. We’ll correct that in an upcoming update.

    any udpates for this to remove validation error?

    We have to stop using this plugin based on a unfixed HTML validation error from 3 months ago.

    Line 29, Column 102: & did not start a character reference. (& probably should have been escaped as &.)

    ….googleapis.com/css?family=PT+Sans:400&subset=latin’ type=’text/css’ media=’al…

    I have followed what JPecsenyicki did, but even after clearing the cache it is still appearing as “&subset” in the page source. The validator is still saying it is invalid.

    Does it need changing somewhere else as well as in google-fonts.php?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘W3C Validation Error’ is closed to new replies.
Skip to toolbar