Drupal

How to add a warning message to your Drupal site the easy way

 You know, you can close a Drupal site anytime for maintenance, don't you? You just go to "Administration -> Site configuration -> Site maintenance" and deactivate the site. From this moment on, no-one can see your website while you're working at it.

Drupal: how to place the Tweet Meme Widget EXACTLY where you want

As you can see in this very article, there's a TweetMeme widget to the right. It's pretty convenient, as it allows any user to post your content to Twitter. And you get this just by installing and configuring the TweetMeme module. Ain't it cool? You get the widget located at the beginning of your node's content. Always. No matter where you really want the widget to be. No matter if you want the widget to be in any other place.

Ummm... that sounds a bit less cool.

So what? What can we do?

How to create an empty page (for Drupal) the easy way

This module creates a Void page. If you need a page to be populated only with blocks, you need the main content of this page to be empty. This is what this module does, as fast as possible. It performs much better than creating an empty module, for example.

Node reference and Views 2: How to define a "refers to nothing" filter

This was a problem I had some time ago, and I'm pretty sure this post will save time to some people.

The problem: Using a Node reference field and Views 2, how do I define a "refers to nothing" condition in the filters?

Solution by merlinofchaos: Add the node reference as a relationship. Then add the Node: Nid filter, set it to the relationship, and set the operator to Is Empty.

What is Drupal good for, part one: Drupal is Bruce Lee

When you get into website building and maintenance, you soon realize that there is no such thing as a “good system for website building and maintenance”. Instead, there are solutions that are “good for this, but not good for that”. You have to choose between different sets of virtues and flaws, so you get the capabilities you need while living with its problems.

You choose the right tool for the job.

Drupal is a good tool. Even more, Drupal is a great tool, an awesome tool. Awesome for what?

Stop SPAM in your Drupal site by being slow.

In this article on SPAM control, we created a tasty honeytrap for our SPAMbot. This trap actually catches about 98% of the SPAM attempts at my site, but we can do better.

The other article used the fact that SPAMbots fill all form elements, even those that are invisible to people. Now we're using the fact that they do it too fast. A person needs time to write on the form. A bot doesn't, unless deliverately the coder introduces in the SPAMbot the ability to wait.

Drupal for multiple languages, part three: all language versions of a node at once

In the first and second articles of this series, we configured Drupal core and content types. Now we're doing something more special in a effort to make our site more usable for our customers and save time when creating new content.

Your Drupal website can now send notifications via SMS

From now on, I can upgrade your site so it can be able to send SMS automatically.

Why? People is not always connected to the Internet, but they always carry their cell phones with them. That's why this service is so useful. You can't be sure they'll read an email from you, but most people reads all SMS they receive before deleting them. If you want to be extra-sure they are properly notified, you can send both an e-mail and an SMS, not a problem.

Modifying the contact form in Drupal: how to add a field

Please notice: This article is for Drupal 6.

It would be great if we could add and remove fields to the contact form the same way we add them to content types using CCK, don't you think? But at this moment, this is not yet possible. As of today, there's no module that let us do it using the control panel. We need to do it "geek way", writing code.

The good news is that, as usual, we don't need to hack Drupal's core. We just use hook_form_alter to make the trick.

OK, let's do it.