0

I've recently had to restore a website after a server crash. I have the majority of the website back up and running.

The problem comes when I flush the cache or disable a module. Images that were being displayed become missing. Looking at Chromes inspector it appears Drupal is looking in the wrong location.

Instead of looking in sites/default/files/styles/footer_blog/public/blog_images?itok=_ZPwwAOU it's looking in sites/default/files/styles/footer_blog/public/?itok=_ZPwwAOU. The images doesn't appear in the edit form either, although I know it's in the directory (sites/default/files/styles/footer_blog/public/blog_images)

The only thing that seems to cure it, is to restore the database but again when I flush the cache the same problem arises.

More Details

I appear to get the following error also

Warning: array_key_exists() expects parameter 2 to be array, null given in theme_image_formatter() in the file modules/image/image.field.inc line 605

  • Have you configured your files directory to be writable by your web server? – Kari Kääriäinen Nov 14 '13 at 12:51
  • Yes, the permissions are currently 777 – thebubbles Nov 14 '13 at 12:53
  • Sometimes it happens when the sub-folders under files directory are not writeable. We mostly use following command to make sure files folder and sub-folders are writeable, chmod -R 777 files – amitgoyal Nov 14 '13 at 13:32
  • Thanks @amitgoyal, I've tried that and it still appears to happen – thebubbles Nov 14 '13 at 13:55
  • Did you get Drupal core and modules and themes from backup or did you download new ones? If you downloaded, did you get the newest versions and ran update.php? – Kari Kääriäinen Nov 14 '13 at 16:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.