Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm running IIS7 and I have fastCGI installed and php code works just fine normally.

Today I added a php file that contained only code an no html markup to the bin directory. And when I try to access it via http, i get a 404 back.

I've verified the file is on the server, and I've verified that the problem goes away if I move the file out of the bin directory.

My question is why does the bin directory hide php files? (and html files too, incidentally.) Is it some IIS security precaution?


share|improve this question

closed as off topic by John Conde, JasonBirch Oct 14 '10 at 20:16

Questions on Webmasters Stack Exchange are expected to relate to webmastering within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

You'll be better of posting this on stackoverflow.com – John Conde Oct 14 '10 at 18:48
If all (you mention PHP and HTML) files in the bin directory are being denied access via the HTTP protocol then it sounds like a security feature set up on your (IIS) server. – w3dk Oct 14 '10 at 19:12
@w3d that's what i was thinking, but would like to know more about the why. @John Conde thanks. done: serverfault.com/questions/191070/… – robertpateii Oct 14 '10 at 19:42
This is a security feature of IIS - mostly for ASP.NET sites, where the dlls are stored in a /bin directory off the main web site. – Eric Petroelje Oct 14 '10 at 21:02

Browse other questions tagged or ask your own question.