Drupal Function of the Day

A while ago our Q&A department decided that it was time to help each other get more educated in Drupal's technology, this to help new colleagues learn and starting to share more knowledge.

After the idea started we immediately realized that this kind of content is useful for everybody and therefore we are sharing it with the world. If you have a suggestion for a call yourself or have comments on specific calls, use the comments form or the contact form to drop us a message.

Database layer in Drupal 7

Evenin,

Okay, this ain't a joke, I'm really talking about db_query(). Well, the upcoming Drupal 7 equivalent of it.

Module_invoke

The function of yesterday is module_invoke. This is a very powerfull function that allows you to reuse behavior of other hooks in your own module. Just give the function call the module name and hook you want to use and the arguments of the hook and you are done!

An Example always helps...

Drupal Javascript object

Hi all,

Let us begin again with a wisdom of our uncle Mark Twain:
"The difference between the right word and the almost right word is
really a large matter — it's the difference between a lightning bug and
the lightning"

For today I have a bunch of functions. Imagine using Javascript/JQuery,
it is sometimes impossible to avoid using texts in your script that

node_view

http://api.drupal.org/api/function/node_view/6


 * Generate a display of the given node.
 *
 * @param $node
 *   A node array or node object.
 * @param $teaser
 *   Whether to display the teaser only or the full form.
 * @param $page
 *   Whether the node is being displayed by itself as a page.
 * @param $links