Drupal 7

Drupal 7 number quizzes

Here are quizzes on magical numbers related with Drupal 7.

How many numbers do you know of them? If you already know all of them, you're an awesome Drupal master certified by hgoto (me)! (But there's no certificate :) )

21 (days)

The default session expiration time. After 21 days (actually 2,000,000 seconds) since the session was created, user sessions expire.

Drupal 7: How to disable a content type

While developing a site with Drupal, at times I'd like to disable a content type without removing it. I just want to disable one.

The database table where content types are stored is node_type. And there's a column disabled in it. We can disabled a content type by changing the column value to 1.

There are APIs for that. We can use node_type_load() and node_type_save() to do it.