You are hereDrupal


Articles related to Drupal, an Open Source Content Management System, that powers this site.

A Drupal site (mainly) without programming

Today Comic-Sammlung.Net went online. Well, layout is still to be done, and the functionality sure will increase (there are non-hierarchical relations to be implemented, and user reviews will be integrated, too), but for now its OK (and gives the search engines something to do).

The site contains information about nearly 90.000 German comics, grouped into more than 6.000 comic series and categorized by topic, style, and publisher. The project was realizes in Drupal with (nearly) no special programming, but with sole use of Content Construction Kit and Views module.

Maintaining Drupal Userreview module

I'm maintaining the Drupal userreview module now and hope to do the first round of bug fixing before Christmas.

How to update Drupal while preserving all your changes

Let's face it: Updating a Drupal instance can be a pain, especially, if your Drupal installation is full of custom patched, like mine is. Wouldn't it be nice to have an installation that can be updated safe and easily? This article is about how I achieved this.

As you may know, Drupal uses CVS. In simple words, CVS allows several developers to work on the same file at the same time. Therefore developers can apply changes without overriding the changes of others - at least to some extend. Different changes to the same line of course need manual resolution.

General Comments on Drupal's Error "Unknown table 'n'"

Maybe you already know the famous Drupal error "Unknown table 'n'". It looks like this:

user warning: Unknown table 'n' in where clause query: SELECT DISTINCT(node.nid), node.type AS node_type, node.title AS node_title, node.changed AS node_changed, AS users_name, users.uid AS users_uid, node.created AS node_created, node_counter.daycount AS node_counter_daycount FROM node node LEFT JOIN users users ON node.uid = users.uid LEFT JOIN node_counter node_counter ON node.nid = node_counter.nid INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = -1 AND na.realm = 'all') OR (na.gid = 0 AND na.realm = 'og_public') OR (na.gid = 0 AND na.realm = 'og_all') OR (na.gid = 3 AND na.realm = 'og_subscriber') OR (na.gid = 4 AND na.realm = 'og_subscriber') OR (na.gid = 0 AND na.realm = 'cac_lite'))) AND (n.moderate != 1) AND (node.status = '1') ORDER BY node_counter.daycount DESC LIMIT 0, 5 in /home/orbit42/public_html/includes/ on line 120.

This error is caused by some module "rewriting" a query of some other module, each of them not aware of each other. This is a powerful Drupal feature, yet it also is highly error prone - as the lots of error alike show. Here's how to deal with it.

Comment Spam: I'm sick of it - Drupal Version

I once wrote about how captchas helped me to get rid of WordPress comment spam. After the last - unfortunately quite successfull - spam attack on my now Drupal-powered web site, I decided to implement the same approach. Simple spoken, captchas are a kind of challenges that should ensure a real human is submitting a form, not a machine. Here are my experiences.

Related nodes updated for Drupal 4.7

The Drupal related nodes code snippet has been updated to work with Drupal 4.7.

TotalFeeds Module supports Drupal 4.7

The Drupal TotalFeeds Module has been updated to work with Drupal 4.7. Additionally, two patches provided by Daniel Ellison have been incorporated. The module now supports feeds for all comments, and the dc:creator tag. You can download it here. The version for Drupal 4.6 is still available here.

Drupal as MVC Framework?

Peter Van Garderen talks about Drupal as a MVC framework. His essay is well worth a reading and so are the comments. Peter writes that

I had considered Drupal as an option earlier but I had been swayed by all the buzz in the tech press and blogosphere about the new generation of open source MVC frameworks that are promising to improve the speed and quality of web application development.

Since Drupal has been around a bit longer than the more recent MVC frameworks, it never thought to sell itself to new developers like myself as a MVC framework. It started out as website content management system and has grown over the past five years into a swiss army knife type toolkit for building websites that is host to an active community of contributors.

Swiss army knife: That's to the point, couldn't agree more :-). However, he concludes that Drupal is not a true MVC framework, but that developing is promising.

Drupal Most Popular Posts Block

I'm currently experimenting if and how presenting users links to other content of this site affects the site navigation (and how you may have guessed: Yes, I got myself a Google Analytics account, too). First I decided to display related articles beneath each articles. Now I'm trying a "Most popular" block that displays the top five pages visited within the last three days. Here's how I did it.

Display related nodes in Drupal

I just hacked the following code into my node.tpl.php to display five possible related nodes beneath each story. There also is a module doing this, however, I wanted to reuse the build in search, since it offers this nice snippets feature.