Link to home
Start Free TrialLog in
Avatar of dprice7
dprice7

asked on

differences between html and htm

This is probably a really dumb question but what is the difference between htm and html code extensions?

I seem to have both and it is causing broken links.

thanks in advance,

Don
Avatar of StormyWaters
StormyWaters
Flag of United States of America image

They're the same.
htm was created when 8.3 filenames (8 character filename, 3 character extension) were still very common, html had 4 letters and needed to be shortened. Now it's just a matter of preference.
Avatar of cachedVB
cachedVB

The reason it can be either is this:
Windows used to only allow 4 character extensions, while a few others allowed 4 character extensions to make it easier for the user.  So on windows, it was .htm (3 char limit) and on others it was .html (to make it easy).  Now to make it not have to be a hassle to have 2 file names for every static page you create, you can now use either.
You also need to take the server into consideration.  Only for the default document though.  If a server is set to use index.html as the default it will not use index.htm unless that is also in the list of defaults.  The different suffixes make for different files.  You can have both mypage.htm and mypage.html with completely different content.  They are different files.

Pretty much all computers these days are not limited to the old DOS style of 8.3 names so it really does just leave it to preference.  With that said, even if a computer does have that limit it will still show 8.4 named web pages because that is up to the server hosting the page and not the computer browsing it.
cachedVB meant to say "used to only allow 3 character"

But the other posters have it basically correct.  On a modern computer, there is no difference.  Historically, in certain operating systems could only have file names with 8 letters and 3 more in the extension, or "8.3"  Here's a good article about that: http://en.wikipedia.org/wiki/8.3  It goes into a lot of the weird things that happened when Microsoft worked around that limitation.
One thing to account for is that the XHTML spec has .html as the standard extension name.  so if you are interested in being standards compliant, use html.

if you don't care, then use htm.   But I would recommend using .html as it's good practice to get into a standards habit. No one ever fired somebody for using IBM... er  html.
Avatar of dprice7

ASKER

Wow,

thanks for the overwelming response from everybody!

I guess I should  have phrased my question a little differently.

What I was actually trying to understand was how I ended up with two sets of filenames when I was creating my site?

Didn't know if maybe Dreamweaver was creating with different extensions or what made the htm vs html files.

I wonder if they will let me give everybody 50 points on this one?


thanks ,
Avatar of daleoran
To give everyone above 50 points you will have to increase yours points to 250 then select split points and then you can give each 50 :)

Michael

You probably won't want to increase to 250 though, thats 200 more points.  I recommend just picking 1 and give that person 50, or 2 and give each 25.
SOLUTION
Avatar of huji
huji
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
king_villy has provided you with a long detailed explanation of what we said above. I think the question is answered. Aren't you going to close this quesiton by selecting one or more answers?
Wish I can help
Huji