Advance XHTML Programming Question:
Is XHTML Element Name Case Sensitive?
Answer:
Yes, XHTML element names are case sensitive. All element names must be written in lower case letters.
Here are some valid and invalid XHTML element names:
► <html> - Valid name.
► <HTML> - Invalid name, must use lower case letters.
► <xhtml> - Invalid name, not defined by XHTML specification.
► <Body> - Invalid name, must use lower case letters.
Note to HTML document authors: HTML element names are not case sensitive. But XHTML element names are case sensitive. If you are converting existing HTML documents to XHTML documents, you will get a lots of syntax errors about upper case letters used in HTML tags.
Here are some valid and invalid XHTML element names:
► <html> - Valid name.
► <HTML> - Invalid name, must use lower case letters.
► <xhtml> - Invalid name, not defined by XHTML specification.
► <Body> - Invalid name, must use lower case letters.
Note to HTML document authors: HTML element names are not case sensitive. But XHTML element names are case sensitive. If you are converting existing HTML documents to XHTML documents, you will get a lots of syntax errors about upper case letters used in HTML tags.
Previous Question | Next Question |
How To Enter Element Content? | What Is an XHTML Element Attribute? |