So my newly created WCF ReST service (or webHttp service, as MS more accurately like to call it) runs fine in Visual Studio 2012, using IIS Express. But when I switch to IIS proper (in my case, IIS8 on Windows 8) I get:
HTTP Error 404.17 – Not Found
The requested content appears to be script and will not be served by the static file handler.
Most so-far extant posts on how to fix this, refer to how to fix it for .Net 3 on Windows before Win8: Use
"%WINDIR%\Microsoft.Net\Framework\v3.5\Windows Communication Foundation\ServiceModelReg.exe" to register or to repair registration of WCF components. (The other gotcha being, having the right AppPool settings for .Net version & for 32 vs. 64 bit).
This doesn’t work for Windows 8 / .Net 4.X. Instead you must open the control panel “Turn Windows Features On or Off” and tick the box for Http activation:
Which should fix the issue after a couple of minutes.