[drupal-docs] Please add your username to the Log entry when you revise a Handbook page

Charlie Lowe cel4145 at cyberdash.com
Mon May 30 20:50:39 UTC 2005


I should add that we would need to have Dries approve changing the code 
on this page before we can implement it since accessing the username and 
date for the revision is a little more complex. So keep any suggestions 
for updating the code up to his standards.

Charlie Lowe wrote:
> The handbook/updates page is a page with PHP code created by Dries (see 
> below). If someone would like to add in the revision username and date, 
> we can update that display.
> 
> Meanwhile, might be good to think about updating the revisions tab with 
> log messages, too.
> 
> Djun Kim wrote:
> 
>>On 30 May 2005, at 1:13 PM, Charlie Lowe wrote:
>>
>>
>>
>>>If anyone is making signficant changes (anything other than minor
>>>proofreading changes), revision should be left enabled. The username 
>>>and
>>>date is then provided through the revisions tab. Any reason to 
>>>duplicate
>>>this information in the log message itself?
>>
>>
>>     Yes  - it makes this information visible in the 'Handbook updates' 
>>summary,
>>for example.  It also provides a concise "Who/What/When/Why" view, which
>>would require grovelling through multiple revisions pages and some
>>guessing to get at otherwise.  It also gives a quick overview of what's
>>going on for a page which is in moderation.
>>
>>     Probably a better long-term solution is to improve the presentation 
>>of
>>this information in book.module, but in the meantime, it's not an 
>>onerous
>>requirement, and it's probably a good discipline in that it makes us 
>>think
>>about what it is we're doing :)
>>
>>     Djun
>>
> 
> 
> <?php
> 
> $result = db_query_range("SELECT n.nid, n.title, n.moderate, n.changed, 
> b.log FROM {node} n INNER JOIN {book} b ON n.nid = b.nid ORDER BY 
> n.changed DESC", 0, 30);
> 
> while ($page = db_fetch_object($result)) {
>    $rows[] = array(l($page->title, "node/$page->nid") .' '. 
> theme('mark', node_mark($page->nid, $page->changed)) . ($page->log ? 
> "<br />$page->log" : ''), t('%time ago', array('%time' => 
> format_interval(time() - $page->changed))), ($page->moderate == 1 ? 'no' 
> : 'yes'));
> }
> $header = array('Page', 'Updated', 'Approved');
> 
> print theme('table', $header, $rows);
> ?>



More information about the drupal-docs mailing list