In general you need to deploy everything except source code files (.cs or .vb
) and project files (.sln, .csproj, etc). However, if a webpage refers to source file using the "src=" attribute in the page directive, then that source file also has to be deployed.
Visual Studio will deploy the correct files for you if you use Project..Copy Project to deploy the files to a webserver using the FrontPage Server Extensions.
Most ASP.NET file extensions are not permitted to be downloaded. This assumes there are no security holes on the web server :-)