Wednesday 18 May 2011

Recover lost page in Drupal

Did you ever lost a page, in Drupal CMS, without having a backup copy?

It happened to us yesterday.

While working on repeating and rather boring task of pasting a chunk of the same code in many existing pages, my co-worker made a mistake and deleted content of a very important page.

It took us some time to realize what exactly the problem was. Since it was the front page, we thought that the site was not working at all.

The only backup, unfortunately was some 20 days old.

I tried to find some solution googleing about it. First few results clearly explained that Drupal, by itself, does not have some kind of recycle bin. Even the worst fact was that the page was not deleted at all, just completely overrun by the wrong piece of replacement code :-/

Thanks to this post: http://drupal.org/node/392326 we found the solution.


If your page has been online for some time, you can find it by google search, searching by it's url (to get it on top of results). The result has one link labeled "cached" and if you are lucky, cached page will be your exact version that got "lost".

Tuesday 17 May 2011

Why I love Drupal

Some two years ago, I was starting as a web developer. The same job I work today.
I did not have much experience at real web programming work, only by doing some occasional jobs.

My task, among the rest, was to make a website consisting of some hundred pages. But the real problem is that it supposed to have 115 pages in ONE SINGLE language. Since it was a tourist and traveling services web, it had to have content in 6 languages (two last flags are fake). So I'm talking about almost 700 pages.



I knew I had to use some open source CMS but my short experience on Joomla was not so good. I remember I had been trying to change it's default templates or to turn some custom HTML page into it's template without much success.

Then I stumbled upon Drupal CMS. Despite that my "headache" went worse those days, I started to read it's documentation. After some 5-6 evenings at home, learning for an hour or two a day (after my exhausting daily job) I decided to go for it.


The next step was to find a way to turn regular HTML theme into Drupal theme. I found video podcast on http://mustardseedmedia.com/podcast/episode24 which made it pretty easy to do.
Also a Drupal documentation at http://drupal.org/node/313510 explains it nicely.

This themes making step was the key point.

I did the web site. You can see it at http://accommodation-split.net

Later, to make use of blocks, menus, modules, use JavaScript and PHP code in pages was an easy thing.

And, it saved my job.