Php – IIS | PHP Error: No input file specified

iisPHP

Im running IIS 7.5 / PHP 7.0 CGI. If i open a non exist .php file in my browser, i get this error:

No input file specified.

IIS don't use the 404 Error Page for .php, like in .html files. I found some solutions, for example set doc_root in php.ini or comment out open_basedir .. but it won't help. I know it's a server issue, but not which.

The question is: Why i get "No input file specified." output, if i open a non exist .php file and not the IIS 404 Error Page?

Best Answer

I found the solution: IIS 7 > Site > Handler Mappings > Edit handler > Request Restrictions > Mapping tab > Check "Invoke Handler only if request is mapped to:" > Select "File or folder"