Hi

As proposed in the previous thread, I would to make a suggestion to modify the output of this block.
Following is a sample output:

______________________________

About this node

* Node ID (NID): 7
* Node type: Page
* Created:
o on Feb 4 2008 - 2:15pm
o by admin
* Last updated:
o on Feb 8 2008 - 12:53pm
o by admin
* Published: Yes
* Promoted: No
* Stickied: No
* Commenting: Module not enabled
_______________________________________

It would be nice if there was GUI for admin to modify this structure.. to anything as per his requirements....
say,
==========================
This page was last updated on Feb 8 2008 - 12:53pm
==========================

Please update us if you are planning to add this feature.
Thanks

Comments

sankett’s picture

Version: 5.x-1.0-rc » 5.x-1.0
sankett’s picture

Is there only me here to discuss?

Well fine, all I wanted to say is:

The current design is good for admin users. For other unregistered user visiting the site, its enough to know when this page was last updated or something else; But just that, unregistered users don't need to the complete node details.

Is there any other module that has this functionality and so you are not planning to implement it?
Please let me know, so that we can think ahead of where we are right now.
Thanks

sankett’s picture

Hey Todd,

I am thinking of modifying this module so that,
1) we can have a GUI to choose what can be displayed.

Lets say we what to display:
a) This page has been updated by admin on Feb 19, 2008.
or
b) This page has been last updated on Feb 19, 2008.
or
c) This page was created on Feb 19, 2001.
etc

If user can decide the layout, it would be nice.
I can easily read this means a lot of work, but are you in support of this feature list?
Do you think its justified? Or do you know any other project that gives the above functionality and so you ain't planning to add it.
Lets discuss the chances....
Thanks

todd nienkerk’s picture

@sankett: Great suggestions. (And sorry for the lengthy delay.) I originally intended it to be used exclusively as a helpful tool for site admins and editors -- not regular users -- but I understand that it could be useful for everyone. I'll need to spend some time considering how to best implement a UI for changing the output.

sankett’s picture

ya thanks todd,

well I have modified your about_this_node.module see below:

_______

/**
 * Theme function that build the block's output for nodes
 */
function theme_about_this_node_node($node_info, $node) {
/**
** patched on 3/4/2008 
** this complete function will be restored if commenting is reversed.
** author sankett
**/

  if (isset($node_info['updated']['value']['updated_on']['value'])) {
    $node_info['updated']['value']['updated_on']['value'] = format_date($node_info['updated']['value']['updated_on']['value'], 'long');
  } elseif (isset($node_info['created']['value']['created_on']['value'])) {
    $node_info['updated']['value']['updated_on']['value'] = format_date($node_info['created']['value']['created_on']['value'], 'long');
  }
  $last_updated_time = $node_info['updated']['value']['updated_on']['value'];
  $message = "<center>This page was last updated on $last_updated_time.</center>";
  return $message;
//  return theme('item_list', about_this_node_prepare_info($node_info, 'small'));
}

_______

This will display a message: $message.
With your module in the blocks section I can now move this $message anywhere.
We can think of allowing user to freely include folowing things in his preformated $message.
You have worked the sql and everything to fetch them... and they are in $node_info.
Lets work on this to have a nice module there.
Cheers!

todd nienkerk’s picture

Status: Active » Closed (works as designed)

@sankett: Thanks for showing me what you've done with the module.

What you've pasted in, however, tells me you're not really interested in using this module as it was originally intended. You could save yourself a lot of work by building your own theme-level function that looks up the node's last updated time and outputs it. Running the entire module just to override its output and spit out one line seems like a lot of overheard with little payoff.

(Also, the <center> tag was deprecated in HTML 4.01 and is entirely unsupported in XHTML 1.0 Strict DTD. You can read more here.)