Experimental project

This is a sandbox project, which contains experimental code for developer use only.

Overview

This module allows you to add a field to nodes that shows the last modified date of that node.

Features

The modules allows site wide or per-page customization of

  • The displayed text
  • The date format
  • Text color
  • Font style (italic and bold)
  • Horizontal rules before or after the text.

Requirements

This module does not require any other modules except the Drupal core. This module only works with Drupal 7.


Here is a look at the global settings page

If the 'Allow override' checkbox is checked, each page with the last modified field will allow customization of these options. If not, they will all take the global options.

Here is the settings widget on the edit page screen:


If you chose default values for these settings when adding the field, those defaults will be seen here. If not, the global settings are used as the default settings.

Installation

  • Upload the module to your 'sites->all->modules' folder.
  • Enable the module.
  • Edit global settings at 'config/content/last_modified_field'.
  • Go to the content types page at 'admin/structure/types'.
  • Click 'manage fields' on the content type you wish to add the last modified field to.
  • On the next page: in the 'add new field' section, enter a name for the field.
  • From the 'Field Type' dropdown, select 'Last Modified Date.'
  • The widget should change to the 'Last Modified Widget.'
  • Press 'Save.'


Note: Previously existing content of the type you just set up will not show the last modified field until the node is updated.

Project information

  • Created by psatyshur on , updated