Help! Google Custom Search Fails W3C Validation

Discussion in 'HTML & Website Design' started by larssonk22, May 20, 2009.

  1. #1
    I've just added the Google Custom Search code into my template and plan to insert google analytics code. I ran the page through W3C Markup Validation Service which found 4 errors within the code, I've highlighted the error in red.

    Line 33, Column 93: cannot generate system identifier for general entity "t13n_langs"
    
    …m/coop/cse/t13n?form=cse-search-box&[COLOR="Red"][B]t[/B][/COLOR]13n_langs=en"></script>
    Code (markup):
    Line 33, Column 103: reference not terminated by REFC delimiter
    
    …/t13n?form=cse-search-box&t13n_langs[COLOR="Red"][B]=[/B][/COLOR]en"></script>
    Code (markup):

    Page was created with a XHTML 1.0 Strict doctype. Page validates perfectly without the google code.
     
    larssonk22, May 20, 2009 IP
  2. pipes

    pipes Prominent Member

    Messages:
    12,766
    Likes Received:
    958
    Best Answers:
    0
    Trophy Points:
    360
    #2
    Im guessing they dont allow their code to be edited in anyway.
     
    pipes, May 20, 2009 IP
  3. larssonk22

    larssonk22 Well-Known Member

    Messages:
    236
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    103
    #3
    I assume so, is it possible to insert the code in a css file?
     
    larssonk22, May 20, 2009 IP
  4. Masim man

    Masim man Active Member

    Messages:
    73
    Likes Received:
    4
    Best Answers:
    2
    Trophy Points:
    58
    #4
    Try to change character & with Entity code: &amp;

    ...search-box&t13n_langs=en">

    change to:

    ...search-box&amp;t13n_langs=en">
     
    Masim man, May 20, 2009 IP
  5. larssonk22

    larssonk22 Well-Known Member

    Messages:
    236
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    103
    #5
    Thanks I'll try using the &amp;, hopefully it wont mess things up on google's end.
     
    larssonk22, May 21, 2009 IP