I would like to see a token, specifically within rules, to allow the display of a published date [node:pub-????], similar to the modified date [node:mod-????]. I don't know if anyone else would really need this and I can live without it, but I have setup a rules schedule to unpublish a node and on the 'expiration' of the node, it sends me an e-mail to let me know that the node has 'expired' or become unpublished. The expiration is set on the node creation and another one on a node re-publish. It's for the 're-publish' that I am looking for a [node:pub-????] token to specify for example: Node was last published on: [node:pub-mm]-[node:pub-dd]-[node:pub-yyyy] and expired on [node:site-date-mm]-[node:site-date-dd]-[node:site-date-yyyy]

I don't know if I even have the format right for the [node:pub-dd] etc. That is the other request I have (I'll just kill 2 birds with one stone here) which is to add a few examples to the descriptions of [node:mod-????] How exactly are we supposed to format that token without spending half an hour tinkering with it to figure it out?

Comments

rudders’s picture

I would expect that the ongoing take-up of Drupal in the enterprise market would drive this sort of functionality. Personally I'd like to see the revisions system operate more like a version management system. Each revision needs a publication date stored for immediate publication, an option to set a future publication date (to the minute) and an expiry date and actions to match. The current "created and updated" dates are not very useful for sites where the act of creation and update is quite different from publication. This could all be quite unobtrusive to existing sites by introducing new dates into the metadata model rather than re-purposing create and update date.

Dave Reid’s picture

Status: Active » Fixed

The published date tokens are available as the direct date 'tokens', i.e.: [yyyy], [mm], [dd].

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Deciphered’s picture

Status: Closed (fixed) » Active

Correct me if I am wrong, but that is the created date, not the published date. Drupal doesn't actually store the published date and therefore you can't have a published date token.

I am however about to release a very simple module that adds the Published date to Nodes, but it doesn't have token integration (yet).

Cheers,
Deciphered.

Dave Reid’s picture

Status: Active » Fixed

Drupal uses created date as the published date, so there's nothing else token can support as it only provides tokens for core.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.