17 replies [Last post]
nickandjules
Offline
Regular
Last seen: 12 years 5 weeks ago
Timezone: GMT+1
Joined: 2007-02-04
Posts: 45
Points: 0

For a standards compliant website is there any recommendation on whether *.htm or *.html should be used?

gary.turner
gary.turner's picture
Offline
Moderator
Dallas
Last seen: 10 weeks 4 days ago
Dallas
Timezone: GMT-6
Joined: 2004-06-25
Posts: 9776
Points: 3858

It matters not one bit. I

It matters not one bit. I prefer .html, but that's just me. I also think .htm seems a bit microsoftish or amateurish, but that, too, is just me.

cheers,

gary

If your web page is as clever as you can make it, it's probably too clever for you to debug or maintain.

nickandjules
Offline
Regular
Last seen: 12 years 5 weeks ago
Timezone: GMT+1
Joined: 2007-02-04
Posts: 45
Points: 0

Thanks for that, I'll go html

Thanks for that, I'll go html

gary.turner
gary.turner's picture
Offline
Moderator
Dallas
Last seen: 10 weeks 4 days ago
Dallas
Timezone: GMT-6
Joined: 2004-06-25
Posts: 9776
Points: 3858

nickandjules wrote:Thanks

nickandjules wrote:
Thanks for that, I'll go html

I can see you're a man of some intelligence, agreeing with my viewpoint so readily. Laughing out loud

cheers,

gary

If your web page is as clever as you can make it, it's probably too clever for you to debug or maintain.

roytheboy
roytheboy's picture
Offline
Guru
North Wales, UK
Last seen: 7 years 42 weeks ago
North Wales, UK
Timezone: GMT+1
Joined: 2004-09-18
Posts: 2233
Points: 41

The correct file extension

The correct file extension to use is .html. This was the standard set in the very beginning of the web as we known it, and is still the default suffix used by apache, which powers the majority of web servers on the planet.

The .htm suffix was introduced by Micro$oft with Windows 3.x because, I think I'm right in saying, it could only handle three letters. Thus, and as usual, even though M$ were late into the game, they still decided to ignore global standards and go their own way rather than build their systems to cope with longer file names (as they did with Windows 98 I believe).

Windows fans will tell you that the use of three letters saves bandwidth, but Windows is hardly the most resource efficient system out there, so it's a trite point.

These days, most (but not all) sysadmins specifically configure their apache servers to recognise the .htm suffix but as the standard and default config option is .html, this ought to be your suffix of choice. The use of the four-letter suffix remains the mark of a 'proper' coder in the eyes of traditional coders, but in practice it makes no difference if portability is not an issue.

Life's a b*tch and then you die!

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 6 years 18 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

Just bear in mind that it

Just bear in mind that it matters NOT one little bit.

Linux types - in their belief in superiority in all matters - will scorn and mock anyone that uses a 3 character suffix which is a hangover from the 8:3 restrictions of early Windows systems. Now of course if you want to be really cool you would use .htm just to fly in the face of convention.

A similar thing exists with the newish use of the term 'Folder' to incorrectly refer to 'Directories'. Directory is the correct method of refering to the structure used to sub divide a hard drive into managable sections, to call a folder a folder er to call a directory a folder is just wrong Smile

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

roytheboy
roytheboy's picture
Offline
Guru
North Wales, UK
Last seen: 7 years 42 weeks ago
North Wales, UK
Timezone: GMT+1
Joined: 2004-09-18
Posts: 2233
Points: 41

The words 'pot', 'kettle'

The words 'pot', 'kettle' and 'black' come to mind Hugo. Are you not one of the most vociferous promoters of the 'standards' mantra?

And it does matter one little bit, because like I said, not every web server out there on the net is configured to recognise .htm - it's a hack for Microsoft in the same way as we hack our css files.

Life's a b*tch and then you die!

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 6 years 18 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

Yeah , I shouldn't have

Smile Yeah , I shouldn't have said that, I think that it probably is virtually safe to use but I don't, in the same way I wouldn't use PHP short tags.

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

thepineapplehead
thepineapplehead's picture
Offline
Guru
Last seen: 8 weeks 9 hours ago
Joined: 2004-06-30
Posts: 9674
Points: 810

Are there any other

Are there any other well-known 4-letter file extensions? I honestly can't think of any off the top of my head.

But that's probably because I come from a Windows environment, with .pdfs, .jpgs, .gifs, .docs and more.

I suppose they're actually JPEG files though, aren't they? Oh yeah and .tiff which MS b***ardised to .tif Tongue

Verschwindende wrote:
  • CSS doesn't make pies

roytheboy
roytheboy's picture
Offline
Guru
North Wales, UK
Last seen: 7 years 42 weeks ago
North Wales, UK
Timezone: GMT+1
Joined: 2004-09-18
Posts: 2233
Points: 41

.html .jpeg .tiff .mpeg .wave

.html
.jpeg
.tiff
.mpeg
.wave
.aiff
.text
.latex
.class
.gzip
.vrml
.sgml

...and probably a few more besides Smile

Life's a b*tch and then you die!

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 6 years 18 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

and in

and in theory:

index.hugosfiles

must reconfigure my servers.

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

roytheboy
roytheboy's picture
Offline
Guru
North Wales, UK
Last seen: 7 years 42 weeks ago
North Wales, UK
Timezone: GMT+1
Joined: 2004-09-18
Posts: 2233
Points: 41

...and for some of the

...and for some of the so-called commercial website pages I see on the web, we ought to have: .crap Wink

Life's a b*tch and then you die!

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 6 years 18 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

Exactly, and for lovely work

Exactly, and for lovely work such as ours we need:

.standardscompliantnicecode

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

roytheboy
roytheboy's picture
Offline
Guru
North Wales, UK
Last seen: 7 years 42 weeks ago
North Wales, UK
Timezone: GMT+1
Joined: 2004-09-18
Posts: 2233
Points: 41

.cool (say no more) .arhh

.cool (say no more)
.arhh (for brightly coloured pages with loads of animated icons)
.loud (for pages that automatically play terrible music at full volume)
.phaw (for pages with attractive women, or men I suppose!)
.knob (for pages written by people who shouldn't be allowed near a computer)
.bles (for pages with pictures of babies and kittens)
.trol (say no more)

Life's a b*tch and then you die!

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 6 years 18 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

and: .adsensepointlesspage

and:
.adsensepointlesspage

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

wolfcry911
wolfcry911's picture
Offline
Guru
MA, USA
Last seen: 7 years 10 weeks ago
MA, USA
Timezone: GMT-5
Joined: 2004-09-01
Posts: 3224
Points: 237

I see a new sig coming...

I see a new sig coming...

Chris..S
Chris..S's picture
Offline
Moderator
Last seen: 8 years 34 weeks ago
Timezone: GMT+1
Joined: 2005-02-22
Posts: 6078
Points: 173

Just to let you all know

Just to let you all know microsoft has joined the party ...

.aspx
.ascx
.master

roytheboy
roytheboy's picture
Offline
Guru
North Wales, UK
Last seen: 7 years 42 weeks ago
North Wales, UK
Timezone: GMT+1
Joined: 2004-09-18
Posts: 2233
Points: 41

...as late as ever!

...as late as ever!

Life's a b*tch and then you die!