December 13, 2009

Never forget the Drupal cache

Had my first experience with Drupal 5 today when I was trying to install a multisite that i checked out from work the other day on my mamp localhost.

First thing was to set up the hosts file to point back to the local installation and second thing was to try and figure out what database to load to which site. Very exciting as usual when live db’s are not named the same thing as internal work db’s.

First site worked fine supringsingly enough. Things never work the first time so of course I became suspicious. Trying the second site problems started. It seemed the site was only loading in the first bit of html code. No CSS, no JavaScript and no images were loaded. Hmm!

After spending some hours poking around the databases, trying different setting and setting up virtual hosts and gaining nothing but irritation and desperation I figured I might try and change the theme and see what happends.

Well enough, after entering the path to change theme i the url, the browser works for a while with a white screen and I start fearing for a WSOD (white screen of death). Supringsingly in a flash, the whole page loads, CSS, images, scripts and content. w00t!

Moral of the story?

Whenever problems occur with content/scripts/css loading. Do NOT go to the databse first and poke around. Try to change the theme. It will save you time!