On a recent Drupal Stack Exchange question a user said that many times designers have problems when moving a site from development to a production server due to issues with the .htaccess file. And, that these 2 lines in the default Drupal .htaccess file cause problems:
# Don't show directory listings for URLs which map to a directory. Options -Indexes # Follow symbolic links in this directory. Options +FollowSymLinks
And that these 2 lines should be removed typically, and he what the common solutions are for this problem and how to secure the website if these lines are removed.
My Solution and Explanation of this Issue
I have actually seen this issue before myself when moving a project from my development system to hosting providers provided by my campus institution. My laptop has very liberal server configurations, I don’t worry much about my local laptop security due to strict network security and running a local firewall. But, the remote server administrators may limit what Apache Overrides may be available on Production systems. So my reply to this issue was:
This is a known issue, see: https://www.drupal.org/node/1269780 regarding a long term resolution.
In general it looks like going forward +FollowSymLinks should be replaced with +SymLinksIfOwnerMatch, but refer to the issue queue item above for a definitive answer.
Typically per host, and definitely with Shared Hosting plans it’s up to your webhosts documentation as to what Apache Overrides are allowed by your (system) user account. There is a certain amount of trial and error is seeing if -Indexes for example is allowed by your hosted webserver configuration.
In step #8 of How To Update Drupal Core it is recommended you backup the .htaccess and robots.txt files of your Drupal site. This is because per webserver these files are highly likely to be modified to work for that system and domain name.
I hope this issue and succict informative note on the recommended resolution helps you to deploy your projects with more ease!
Looking for quality web hosting? Look no further than Arvixe Web Hosting!