Blank WordPress theme (and admin) issue

Few days ago I got a notice that one of site (running on WordPress) displays only header image and users are unable to see admin panel after login form. It seemed that all the content after header is disappeared. Turning on the debug mode didn’t show a thing and all I got was access to files via web based FTP.

With a little hint from support forum I did manage to turn the whole page visible again and here’s a short overview:

  1. Rename themes folder (to themes2, for example)
  2. Log in (you are now able to log in to admin panel)
  3. Delete active theme (or back it up to your hard drive)
  4. Rename themes2 folder to themes again
  5. Activate some “safe” theme (Twenty Eleven works fine)

As you probably understood already, problem was somewhere in the current theme. In my case, I’ll need to find broken code on my local computer before moving it back to working server. But at least site is up and running again.