Sweepster
Sweepster

Reputation: 1949

syntax error for xhtml doctype in header

Firebug is reporting a syntax error for the following:

<!DOCTYPE html PUBLIC "-//W3C XHTML 1.0 Transitional//EN" "DTD/xhtml1- transitional.dtd"> 

I don't understand why since it has worked fine for the past 2 months!

Upvotes: 7

Views: 6588

Answers (1)

Quentin
Quentin

Reputation: 943108

You are trying to load an HTML document as JavaScript, either because you are sourcing a 404 document or because you've forgotten to add the URI and thus created a relative URI back to the current document (<script src=""></script>).

When interpreted as JS, the Doctype is a syntax error.

Upvotes: 12

Related Questions