开发者

Drupal: Node Submission Time

How do I print into a block the node submission time. something li开发者_如何学JAVAke... print $node->submitted_time?


$node->created is what you're looking for.


add block -> choose php filter, add code:


if ((arg(0) == 'node') && is_numeric(arg(1)) ) {
  $node = node_load(arg(1));
  if ($node) {
    print format_date($node->created);
  }
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜