WebDAV default .htaccess settings tries executing PHP files

As it is currently set up, when you try to copy/paste PHP files back from WebDAV - you can’t retrieve them because they got executed on the server instead of copied back (you just get result of the PHP file execution instead of PHP file itself). In order for this to work for PHP files - this is change is needed in .htaccess:

RemoveHandler .php
ForceType text/plain

When people are using WebDAV (e.g. a mapped network drive), you can bet that none of them wants the PHP files to be executed but to act as a normal file. This means that this change should be standard option in WebDAV configuration, not special case where one has to contact support for change.


thanks for the feedback. I have forwarded it to product managers for their consideration.

One thing to be aware is that you should be able to modify the .htaccess file yourself but that implies that you know what you’re doing. Not ideal, I understand.

Some documentation on what is .htaccess and how to change Apache’s behaviors are on DreamHost Knowledge Base.

Thanks for your quick response,

actually I’m unable to directly edit .htaccess file for WebDAV folder(s) - it is protected and I have to ask support to make changes there.

Best regards!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.