The submitted date format of a node is hard coded into node.tpl.php of Zen theme.
So, even if one adds the custom theme function interactive_media_node_submitted($node) into template.php, it doesn't work.

I think it is important to know the submitted and last modification date of a node, so I modified template.php and node.tpl.php as following:

  1. diff template.php.original template.php
    217a218,233
    >
    >
    > /**
    >  * Override the submitted info of a node.
    >  * It shows the last modification date when this one differs from the creation date.
    >  */
    > function interactive_media_node_submitted($node) {
    > $data = array(
    > '!username' => theme('username', $node),
    > '@datetime' => format_date($node->created,'medium'),
    > '@updatedate' => format_date($node->changed,'medium')
    > );
    >
    > return t('Submitted by !username on @datetime'.(($node->created != $node->changed)?'; last update on @updatedate':''), $data);
    > }
    >
  2. I have copied the Zen templates/node.tpl.php into templates and modified as
    diff ../../zen/templates/node.tpl.php node.tpl.php
    89,96c89,91
    <       <?php if ($display_submitted): ?>
    <         <span class="submitted">
    <           <?php
    <             print t('Submitted by !username on !datetime',
    <               array(
    '!username' => $name, '!datetime' => $date));
    <          
    ?>

    <         </span>
    <       <?php endif; ?>
    ---
    >   <?php if ($submitted): ?>
    > <span class="submitted"><?php print $submitted ?></span>
    >   <?php endif; ?>

Comments

Assigned:Unassigned» hswong3i
Status:Active» Postponed (maintainer needs more info)

Are you using with zen-6.x-2.0 (http://drupal.org/node/838400) or zen-6.x-2.x-dev (http://drupal.org/node/373826)? The revamp of interactive_media-6.x-2.x-dev are based on zen-6.x-2.x-dev.

I check with the http://drupalcode.org/project/zen.git/blob/refs/heads/6.x-2.x:/templates... and you should able to override the submitted with your own node.tpl.php. Please correct me.

I have installed zen-6.x-2.0.

Perhaps my previous post is not clear: there is no bug in interactive_media. In alpha4 release, it is possible to override Zen node.tpl.php with a custom one as I suggested in order to use a possible custom interactive_media_node_submitted($node) function (as required by Drupal Theme Guideline).

Since I find that Zen node.tpl.php is not a good example of template, I suggest as 'feature request' for interactive_media to fix such not good example overriding it by a more standard node.tpl.php, where custom interactive_media_node_submitted($node) function are used if defined.

Project:Interactive Media» Zen
Version:6.x-2.0-alpha4» 6.x-2.x-dev
Component:Code» PHP code
Assigned:hswong3i» Unassigned
Status:Postponed (maintainer needs more info)» Active

So, if Zen's default template is not good enough, why don't we contribute the changes to Zen as a new standard, rather than manually override it within subthemes?

Please kindly understand that I am going to migrate ALL of my theme contributions as Zen subthemes, and it is now working in progress. Therefore if this should be done within interactive_media, I will fork it for other project, too (and result as duplicated effort for daily maintenance).

In case of zen-7.x-3.x-dev, node.tpl.php is already implement with $submitted as suggested. I think Zen team would like to review with this suggestion, too. I would like to refer this issue to the suitable project.

Title:Submitted and modification date of a nodeAdd $submitted variable back into node.tpl
Status:Active» Fixed

Just before Drupal 7.0 was released, core's node.tpl was modified to no longer hard-code the t() function in it for the submitted date formatting and to once again use the D6-style $submitted variable. See #547696: Update node.tpl to use ideas from D7

Since Zen 6.x-2.0 was released last June, it was modeled after how D7 worked at the time.

Let's get Zen 6.x-2.1 inline with D7.0.

Fixed. http://drupalcode.org/project/zen.git/commit/3b5f9a9

Status:Fixed» Closed (fixed)

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