Reputation: 1467
I am trying to setup Wordpress in a subfolder (/blog) on my ASP.Net MVC app that is hosted on Windows Azure. When I navigate to /blog/index.php, the file downloads instead of executing.
I have done the following:
I've clicked Restart in the portal for the web app.
Still downloads the file instead of executing.
What am I doing wrong?
Upvotes: 0
Views: 1240
Reputation: 1467
Well, turns out that we had a BlockViewHandler sitting in our web.config, which was blocking access to all file types (including .php). This might be unusual, but I'm posting this in case it helps someone else.
The tag we had was:
<handlers>
<add name="BlockViewHandler" path="*" verb="*" preCondition="integratedMode" type="System.Web.HttpNotFoundHandler" />
</handlers>
It is designed to prevent unauthorised/hacking access.
Upvotes: 0
Reputation: 24636
Assuming you're running the site in an Azure Web App, verify that PHP is turned on: Go to the site in the portal -> Settings -> Application Settings -> PHP version
http://azure.microsoft.com/en-us/documentation/articles/web-sites-php-configure/
Upvotes: 0
Reputation: 5665
YOU need to add a Handler Mapping
I am not familiar with Azure, but...
You should have a IIS control panel with a Handler Mappings icon.
Add a Mapping Handler:
Upvotes: 1