{"id":310,"date":"2012-09-16T14:45:57","date_gmt":"2012-09-16T18:45:57","guid":{"rendered":"http:\/\/inkprov.com\/blog\/?p=310"},"modified":"2012-09-16T16:39:30","modified_gmt":"2012-09-16T20:39:30","slug":"how-to-fix-the-directory-sitesdefaultfiles-does-not-exist-error-in-drupal-for-hostgator","status":"publish","type":"post","link":"http:\/\/inkprov.com\/blog\/how-to-fix-the-directory-sitesdefaultfiles-does-not-exist-error-in-drupal-for-hostgator\/","title":{"rendered":"How to fix Drupal error &#8220;the directory sites\/default\/files does not exist&#8221; for HostGator Drupal sites."},"content":{"rendered":"<p>If you run the Drupal status report and see the following error:<\/p>\n<p>The directory <em>sites\/default\/files<\/em> does not exist<\/p>\n<p>It means the directory in your HostGator (or other hosting) does not have the correct permissions to allow Drupal to allow access to the files.<\/p>\n<p>&#8212;<\/p>\n<p>First check your status report to see if you have this error:<\/p>\n<p><a href=\"http:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/Drupal_permissions_issue.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-313\" src=\"http:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/Drupal_permissions_issue.png\" alt=\"\" width=\"768\" height=\"404\" srcset=\"https:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/Drupal_permissions_issue.png 768w, https:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/Drupal_permissions_issue-300x157.png 300w\" sizes=\"auto, (max-width: 768px) 100vw, 768px\" \/><\/a><\/p>\n<p>If the site is experiencing problems with permissions to content, you may have to rebuild the permissions cache. Rebuilding will remove all privileges to content and replace them with permissions based on the current modules and settings. Rebuilding may take some time if there is a lot of content or complex permission settings. After rebuilding has completed, content will automatically use the new permissions. <span style=\"color: #3366ff\">Rebuild permissions<\/span><\/p>\n<p>If this is not fixed before you install modules you will run into trouble.<\/p>\n<p>I have seen this more than once on new Drupal sites with HostGator, not sure why.<\/p>\n<p>Here is what I did to fix:<\/p>\n<p>Got on chat with HostGator by logging into cPanel and clicking the chat icon:<\/p>\n<p><a href=\"http:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/HostGator_cPanelMainPage_ChatSupport.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-315\" src=\"http:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/HostGator_cPanelMainPage_ChatSupport.png\" alt=\"\" width=\"760\" height=\"566\" srcset=\"https:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/HostGator_cPanelMainPage_ChatSupport.png 760w, https:\/\/inkprov.com\/blog\/wp-content\/uploads\/2012\/09\/HostGator_cPanelMainPage_ChatSupport-300x223.png 300w\" sizes=\"auto, (max-width: 760px) 100vw, 760px\" \/><\/a><\/p>\n<p>There is a script that support can run on the server internally to set the permissions to the default settings &#8211; ask them to run the script.<\/p>\n<p>Or you can manually edit permissions in file manager using this hostgator link:<\/p>\n<p><a href=\"https:\/\/support.hostgator.com\/articles\/cpanel\/how-to-change-permissions-chmod-of-a-file\" target=\"_BLANK\">https:\/\/support.hostgator.com\/articles\/cpanel\/how-to-change-permissions-chmod-of-a-file<\/a><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you run the Drupal status report and see the following error: The directory sites\/default\/files does not exist It means the directory in your HostGator (or other hosting) does not have the correct permissions to allow Drupal to allow access &hellip; <a href=\"http:\/\/inkprov.com\/blog\/how-to-fix-the-directory-sitesdefaultfiles-does-not-exist-error-in-drupal-for-hostgator\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-310","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/posts\/310","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/comments?post=310"}],"version-history":[{"count":8,"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/posts\/310\/revisions"}],"predecessor-version":[{"id":312,"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/posts\/310\/revisions\/312"}],"wp:attachment":[{"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/media?parent=310"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/categories?post=310"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/inkprov.com\/blog\/wp-json\/wp\/v2\/tags?post=310"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}