0

Okay, so I'm at a temporary office and they've given me a machine with XP to do dev on. Awesome.

I've set the site up in IIS and I need it to serve shtml files.

Problem is, when I browse to the shtml file, the browser tries to download the file, rather than display it properly.

I've tried a few things that I've found on other site to no avail, and now I'm just getting frustrated.

Any help?!?!

-Ev

William Salzman
  • 6,396
  • 2
  • 33
  • 49
Ev.
  • 7,109
  • 14
  • 53
  • 87

3 Answers3

2

are you serving it with the correct mime type?

shtml simply use the text/html mime type but your IIS might not be configured to match that file extension with that mime type

See http://technet.microsoft.com/en-us/library/cc725608(WS.10).aspx for details on adding mime types (you didn't specify the version of IIS... those docs are for IIS 7)

Jonathan Fingland
  • 56,385
  • 11
  • 85
  • 79
  • Mmmm,it's IIS on XP, so I think that's IIS6. So good advice. I added the mime type but it still tries to download the file. So that didn't work, but I agree, that sounds like the problem... now, why would that not work? In other versions of IIS I can go to Web Service Extensions and switch on SSI or something, but I don't know how to do the equivalent in xp.. – Ev. Jun 17 '09 at 14:39
  • see this: http://support.theplanet.com/kb/operatingsystems/microsoftwindows/iis-60-will-not-serve-my-shtml-files-how-can-i-fix I haven't tested it, but it seems to be the same problem – Jonathan Fingland Jun 17 '09 at 14:52
  • Ah, this is how I usually enable shtml. A quick Google told me that XP actually uses 5.1, not 6.0 as I previously stated. Thanks for the help by the way, @Jonathan – Ev. Jun 17 '09 at 14:57
  • ahh, alright then. I should have checked for that. Glad you got it all sorted out – Jonathan Fingland Jun 17 '09 at 22:15
0

IIS might be configured for .SHTM / .STM file extension. You can either change the extension in the iIS control panel, or rename your files.

TFM
  • 544
  • 5
  • 11
  • Actually, IIS is only configured to use * through C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll This is part of the install of the CMS I'm using in this webapp. do you think this could be causing issues? – Ev. Jun 17 '09 at 14:50
0

Update: I never got this sorted. I suspect the CMS I was using did something odd. So After ****ing around with it for about a day I decided I'd wasted enough time on it and installed Apache to view the SSI files - still use IIs 5.1 for the actual site.

On the production/dev/test/stage environments, with a newer version of IIS it works fine. it was just my local machine I was having problems on.

So not solved, but I'm not losing anymore sleep/time over it!

Ev.
  • 7,109
  • 14
  • 53
  • 87