Creating Notifications In Drupal 7 Using Message Module
https://www.zyxware.com/sites/default/files/styles/user_image/public/default_images/index.png?itok=2YmREnrP
BY jijimol.john
8 months ago
Drupal-7
0
comments comment

As part of a project requirement, we needed to notify users whenever an entity got created, updated, rated or reviewed. Drupal's 'message' module fulfils this requirement.

We can log and display messages and can even customize the notifier plugins. For creating notification, we need to install the following modules:

  • message
  • message_notify
  • message_subscribe

The dependent modules are:

  • Flag
  • Ctools
  • Entity API

We can add message types in admin/structure/messages. In message types, we can add fields with the fields type. When the event is triggered, the rule action is processed for the corresponding messages and it will be saved to the queue table. While cron runs, the message notify plugin processes the messages and delivers it. Message notify module provide us with email and sms notifier.

Message

This module is at the core of message stack. This module help us to create message types.

Message subscribe

This module helps us to register the notified content when an event is triggered. This messages will get stored in the queue table. For preventing looping of messages in the queue system, apply the following patch to the message_subscribe.module .

Message notify

This module is used for sending or viewing messages via notifier plugin. Message notifier has 2 default plugins- email and sms.

Hope this article helps!


RELATED ARTICLE

more_horiz
close

on 24th January 2012 / by webmaster
By default Drupal 7 has two types of views - The Full node view and the Teaser view. This has been the case for all previous versions of Drupal. However if your requirements are different, then you might have to create a custom view that is tailored to meet your specific needs. Check out how to create a simple custom “View mode” for nodes in Drupal 7. Web Development Drupal Drupal Development Drupal 7 Leave a reply Your email address will not be published. Required fields are marker * uk (not verified) access_time 18 Aug 2019 - 17:18 Hi, It would be good if you rename the preprocess function tdbcustom_preprocess_node to CustomModule_preprocess_node Thanks, UK. webmaster access_time 18 Aug 2019 - 17:18 In reply to Hi,It would be good if you by uk (not verified) Thanks for the suggestion. Corrected the module name in the sample code. Add new comment
Leave a reply
Your email address will not be published. Required fields are marker *

Filtered HTML

  • Web page addresses and email addresses turn into links automatically.
  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type='1 A I'> <li> <dl> <dt> <dd> <h2 id='jump-*'> <h3 id> <h4 id> <h5 id> <h6 id>
  • Lines and paragraphs break automatically.
The content of this field is kept private and will not be shown publicly.
CAPTCHA This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.