Capitalize HTML tags?

Posted on 2005-04-23
Last Modified: 2008-01-09
Can anyone give me a definitive answer: should HTML tags be uppercase or lowercase?  Just wondering really.  It seems the W3C site uses lower case for both tags and attributes so I am guessing that is how it should be...

In other words should I write:

<TABLE cellpadding="0" cellspacing="0" border="0">
<table cellpadding="0" cellspacing="0" border="0">

If someone could could point me to the actual guideline I would appreciate it.

Question by:2djohn
    LVL 13

    Accepted Solution

    HTML 4.01 is case-insensitive, but the typical convention now is to use lowercase, because it is required in the next generation, XHTML (Which may or not be phased out, but if a basis in XML remains, lowercase will stay.)
    LVL 31

    Expert Comment

    There are example of case sensitivity eg

    Author Comment

    Thanks Gwynn- but I am looking for something a little more like Stormy's answer.  I realize HTML is not case sensitive.  But thanks for the input.
    LVL 19

    Expert Comment

    Recommended is not to use uppercase characters as Stormy already said, that said...if you do use uppercase, use them concequently to use proper XML syntax.


    Author Comment

    Thanks everyone.  That is what I was hoping for since I have been using lower case for years!

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Training Course: Adobe Dreamweaver CC 2015

    Adobe Dreamweaver Creative Cloud is used by web designers and front-end developers and allows you to visualize your site in real-time as you code. This course covers exam objectives for the Adobe Certified Associate (ACA) certification.

    Deprecated and Headed for the Dustbin By now, you have probably heard that some PHP features, while convenient, can also cause PHP security problems.  This article discusses one of those, called register_globals.  It is a thing you do not want.  …
    Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
    In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
    In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now