The Rate Expiration module allows you to specify a date when you no longer want to accept rating submissions. This is an optional module that comes with the Rate module. In this video, I will show you how to configure the "Usefulness" widget to be disabled one hour after the article is published.

Install modules

Enable modules

  • Go to "Modules" (admin/modules) and enable:
    • Date API
    • Date
    • Rate Expiration
  • (Save configuration)

Edit the Usefulness widget

  • Go to "Structure => Rate widgets"(admin/structure/rate)
  • Click "Edit" next to "This article is useful and clear"

When we scroll down, we'll see a new section for Expiration Settings.

Expiration Settings

  • Disable voting after this period: Choose "1 hour" (Voting will be closed after one hour when the node is created)
  • [ ] Allow override (If enabled, the content creator (or editor) will be able to set both a start, and end date for when voting is active.)
    • (Save)

Now, if we create a new article, everything looks normal, except that the Usefulness widget will automatically be disabled after 1 hour. Let's go back and check the "Allow override" box.

  • Go to "Structure => Rate widgets"(admin/structure/rate)
  • Click "Edit" next to "This article is useful and clear"

Expiration Settings

  • [x] Allow override (If enabled, the content creator (or editor) will be able to set both a start, and end date for when voting is active.)
  • (Save)

Now, if we create a new article, when we scroll down, we'll see the section that allows us to configure the start and end dates for voting. If we leave everything at their default settings, it will be active for one hour like we set in the preferences.

In the next video, we're going to take a look at the built-in bot detection that comes with the Rate module.