本文整理汇总了PHP中comment_date函数的典型用法代码示例。如果您正苦于以下问题:PHP comment_date函数的具体用法?PHP comment_date怎么用?PHP comment_date使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了comment_date函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: my_theme_comment
function my_theme_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
switch ($comment->comment_type) {
default:
?>
<li <?php
comment_class();
?>
id="comment-<?php
comment_ID();
?>
">
<p class="meta-comment">
<?php
echo get_avatar($comment, 30);
?>
<span class="author-name"><?php
comment_author();
?>
</span>
<time <?php
comment_time('c');
?>
class="comment-time">
<span class="date">
<?php
comment_date();
?>
</span>
<span class="time">
<?php
comment_time();
?>
</span>
</time>
</p>
<div class="comment-content">
<?php
comment_text();
?>
</div>
<div class="comment-actions">
<div class="reply"><?php
comment_reply_link(array_merge($args, array('reply_text' => 'Reply', 'after' => '', 'depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div><!-- .reply -->
</div>
<!-- #comment-<?php
comment_ID();
?>
-->
<?php
// End the default styling of comment
break;
}
}
示例2: edu7_comment
function edu7_comment($comment, $args, $depth)
{
?>
<div class="comment-img"><?php
echo get_avatar($comment, $size = '45');
?>
</div>
<div class="comments-box">
<?php
comment_text();
?>
<?php
if ($comment->comment_approved == '0') {
?>
<em><?php
_e('Your comment is awaiting moderation.');
?>
</em>
<?php
}
?>
<br/><span class="comment-writer"> توسط <?php
comment_author();
?>
</span><span class="comment-date"><?php
comment_date();
?>
- <?php
comment_time();
?>
</span> <?php
comment_reply_link(array_merge($args, array('before' => '<span class="comment-replay">', 'reply_text' => 'پاسخ', 'after' => '</span>', 'depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div><br/><?php
}
示例3: mytheme_comment
function mytheme_comment($comment, $args, $depth) {
$GLOBALS['comment'] = $comment; ?>
<li <?php comment_class(); ?> id="li-comment-<?php comment_ID() ?>">
<div id="comment-<?php comment_ID(); ?>">
<div class="comment-author vcard">
<span class="small_frame"><?php echo get_avatar($comment,$size='60',$default=get_template_directory_uri().'/images/gravatar.gif' ); ?></span><br />
<cite><?php comment_author_link() ?></cite><br />
<div class="date"><?php comment_date('M d, Y'); ?></div>
</div>
<div class="comment-text">
<?php if ($comment->comment_approved == '0') : ?>
<em class="awaiting_moderation"><?php _e('Your comment is awaiting moderation.', 'epanel') ?></em>
<br />
<?php endif; ?>
<?php comment_text() ?>
<div class="comment-meta commentmetadata">
<?php edit_comment_link(__('(edit)'),' ','') ?>
</div>
<div class="reply">
<?php comment_reply_link(array_merge( $args, array('reply_text' => '(reply)', 'depth' => $depth, 'max_depth' => $args['max_depth']))) ?>
</div>
</div>
</div>
<?php } ?>
示例4: as_function_comments_better
function as_function_comments_better($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
id="as-li-comment-<?php
comment_ID();
?>
">
<div class="as-comment" id="as-comment-<?php
comment_ID();
?>
">
<div class="as-comment-content">
<?php
echo get_avatar($comment, $size = '65');
?>
<div class="as-comment-meta">
<h4><?php
comment_author_link();
?>
<span><?php
comment_date();
?>
at <?php
comment_time();
?>
</span>
</h4>
</div>
<div class="as-comment-text">
<?php
comment_text();
?>
<?php
if ($comment->comment_approved == '0') {
?>
<p style="font-style:italic;"><?php
_e('Your comment is awaiting moderation.', AS_DOMAIN);
?>
</p>
<br />
<?php
}
?>
<?php
edit_comment_link(__('[Edit]', AS_DOMAIN), ' ', '');
?>
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
</div>
</div>
<?php
}
示例5: zl_custom_comment
function zl_custom_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
id="li-comment-<?php
comment_ID();
?>
">
<div class="medium-1 column norightgap">
<?php
echo get_avatar($comment->comment_author_email, 50);
?>
</div>
<div class="medium-11 column">
<div id="comment-<?php
comment_ID();
?>
">
<div class="comment-author"><strong><?php
printf(__('%s', 'zatolab'), get_comment_author_link());
?>
</strong> <?php
echo zl_option('lang_on', __('on', 'zatolab'));
?>
<em class="zl_commenttime"><small><?php
comment_date();
?>
, <?php
comment_time('H:i:s');
?>
</small></em></div>
<div class="clear"></div>
<div class="zl_comment_content">
<?php
comment_text();
if ($comment->comment_approved == '0') {
?>
<p><em><?php
echo zl_option('lang_commoderate', __('Your comment is awaiting moderation.', 'zatolab'));
?>
</em></p>
<?php
}
?>
<div class="clear"></div>
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
</div>
</div>
<div class="clear"></div>
<?php
}
示例6: webnus_comments
function webnus_comments($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
id="comment-<?php
comment_ID();
?>
">
<div class="comment-info">
<?php
echo get_avatar($comment, 90);
?>
<cite>
<?php
comment_author_link();
?>
<?php
_e('Says', 'WEBNUS_TEXT_DOMAIN');
?>
:
<span class="comment-data"><a href="#comment-<?php
comment_ID();
?>
" title=""><?php
comment_date('F j, Y');
?>
at <?php
comment_time('g:i a');
?>
</a><?php
edit_comment_link('Edit', ' | ', '');
?>
</span>
</cite>
</div>
<div class="comment-text">
<?php
if ($comment->comment_approved == '0') {
?>
<p><em><?php
_e('Your comment is awaiting moderation.', 'WEBNUS_TEXT_DOMAIN');
?>
</em></p>
<?php
}
?>
<?php
comment_text();
?>
<div class="reply">
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
</div>
<?php
}
示例7: reverie_comments
function reverie_comments($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
>
<article id="comment-<?php
comment_ID();
?>
">
<header class="comment-author vcard">
<?php
echo get_avatar($comment, $size = '40');
?>
<?php
printf(__('<cite class="fn">%s</cite>', 'reverie'), get_comment_author_link());
?>
<time datetime="<?php
echo comment_date('c');
?>
"><a href="<?php
echo htmlspecialchars(get_comment_link($comment->comment_ID));
?>
"><?php
printf(__('%1$s', 'reverie'), get_comment_date(), get_comment_time());
?>
</a></time>
<?php
edit_comment_link(__('(Edit)', 'reverie'), '', '');
?>
</header>
<?php
if ($comment->comment_approved == '0') {
?>
<div class="notice">
<p class="bottom"><?php
_e('Your comment is awaiting moderation.', 'reverie');
?>
</p>
</div>
<?php
}
?>
<section class="comment">
<?php
comment_text();
?>
</section>
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</article>
<?php
}
示例8: mytheme_comment
function mytheme_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
id="li-comment-<?php
comment_ID();
?>
">
<div id="comment-<?php
comment_ID();
?>
" class="comment-inner">
<figure class="vcard">
<?php
echo get_avatar($comment, 70);
?>
</figure>
<div class="comment-container">
<div class="commentmeta">
<strong><?php
comment_author_link();
?>
</strong>
<span class="authorname">
<?php
comment_date('M d, Y');
?>
- <?php
comment_time('h:i A');
?>
<?php
edit_comment_link("Edit", '');
?>
</span>
</div>
<div class="comment-text">
<?php
if ($comment->comment_approved == '0') {
?>
<em class="awaiting_moderation"><?php
_e('Your comment is awaiting moderation.', THB_THEME_NAME);
?>
</em>
<?php
}
?>
<?php
comment_text();
?>
<?php
comment_reply_link(array_merge($args, array('reply_text' => __('Reply', THB_THEME_NAME), 'depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
</div>
</div>
<?php
}
示例9: studiofolio_comment
<?php function studiofolio_comment($comment, $args, $depth) {
$GLOBALS['comment'] = $comment; ?>
<li <?php comment_class(); ?>>
<article id="comment-<?php comment_ID(); ?>">
<header class="comment-author vcard">
<?php echo get_avatar($comment, $size = '32'); ?>
<?php printf(__('<cite class="fn">%s</cite>', 'studiofolio'), get_comment_author_link()); ?>
<time datetime="<?php echo comment_date('c'); ?>"><a href="<?php echo htmlspecialchars(get_comment_link($comment->comment_ID)); ?>"><?php printf(__('%1$s', 'studiofolio'), get_comment_date(), get_comment_time()); ?></a></time>
<?php edit_comment_link(__('(Edit)', 'studiofolio'), '', ''); ?>
</header>
<?php if ($comment->comment_approved == '0') : ?>
<div class="alert alert-block fade in">
<a class="close" data-dismiss="alert">×</a>
<p><?php _e('Your comment is awaiting moderation.', 'studiofolio'); ?></p>
</div>
<?php endif; ?>
<section class="comment">
<?php comment_text() ?>
</section>
<?php comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth']))); ?>
</article>
<?php } ?>
示例10: mydesign
function mydesign($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li class="compost" id="comment-<?php
comment_ID();
?>
">
<div class="combody">
<?php
comment_text();
?>
</div><!-- .combody -->
<p class="cominfo">
by <?php
comment_author_link();
?>
<?php
comment_date();
?>
<?php
comment_time();
?>
</p>
</li>
<?php
}
示例11: mydesign
function mydesign($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
$users = get_users();
?>
<li id="comment-<?php
echo comment_id();
?>
" class="compost">
<?php
// ユーザーIDを引っ張る
foreach ($users as $user) {
//echo $user->display_name.'<br />';
//echo get_comment_author();
if ($user->display_name == get_comment_author()) {
break;
}
}
?>
<span class="trick_rounded-img icon_image" style="background: url(<?php
echo ps_get_user_profile_image_src($user->ID, 'standard');
?>
) no-repeat center center; width: 50px; height: 50px;></span>
<span class="trick_thumbnail_Image">
<?php
ps_user_profile_image($user->ID, 'thumbnail');
?>
</span>
<?php
?>
<div class="commentarea">
<?php
//改行表示
$commentstr = '<p>' . get_comment_text() . '</p>';
$commentstr = preg_replace("/\n/", "<br />", $commentstr);
echo $commentstr;
//comment_text();
?>
</div>
<p class="cominfo">
<?php
comment_date();
?>
<?php
comment_time();
?>
|
<?php
comment_author_link();
?>
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'reply_text' => '返信', 'before' => ' | ', 'after' => '')));
?>
</p>
</li>
<?php
}
示例12: py_comments
function py_comments($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
>
<article class="callout" id="comment-<?php
comment_ID();
?>
">
<header class="comment-author">
<?php
echo get_avatar($comment, $size = '96', $default = get_template_directory_uri() . ' /img/yeti-avatar.png');
?>
<div class="author-meta">
<?php
printf(__('<cite class="fn">%s</cite>', 'projectyeti'), get_comment_author_link());
?>
<time datetime="<?php
echo comment_date('c');
?>
"><a href="<?php
echo esc_url(get_comment_link($comment->comment_ID));
?>
"><?php
printf(__('%1$s', 'projectyeti'), get_comment_date(), get_comment_time());
?>
</a></time>
<?php
edit_comment_link(__('(Edit)', 'projectyeti'), '', '');
?>
</div>
</header>
<?php
if ($comment->comment_approved == '0') {
?>
<div class="notice">
<p class="bottom"><?php
_e('Your comment is awaiting moderation.', 'projectyeti');
?>
</p>
</div>
<?php
}
?>
<div class="comment">
<?php
comment_text();
?>
</div>
<footer><?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</footer>
</article>
<?php
}
示例13: cutline_comment
function cutline_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
id="comment-<?php
comment_ID();
?>
">
<?php
echo get_avatar($comment, 48);
?>
<p class="comment_meta">
<strong><?php
comment_author_link();
?>
</strong>
<span class="comment_time">// <a href="#comment-<?php
comment_ID();
?>
" title="<?php
echo attribute_escape(__('Permalink to this comment', 'cutline'));
?>
"><?php
comment_date();
?>
<?php
_e('at');
?>
<?php
comment_time();
?>
</a> <?php
echo comment_reply_link(array('depth' => $depth, 'max_depth' => $args['max_depth'], 'before' => ' | '));
?>
<?php
edit_comment_link(__('edit', 'cutline'), '(', ')');
?>
</span> </p> <div class="entry">
<?php
comment_text();
?>
<?php
if ($comment->comment_approved == '0') {
?>
<p><strong><?php
_e('Your comment is awaiting moderation.', 'cutline');
?>
</strong></p>
<?php
}
?>
</div>
</li>
<?php
}
示例14: print_comment
function print_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class('comment');
?>
>
<div class="comment-body" id="comment-<?php
comment_ID();
?>
">
<?php
echo get_avatar($comment, 70, get_bloginfo('stylesheet_directory') . '/images/avatar.gif');
?>
<p class="author">
<?php
comment_author_link();
?>
</p>
<p class="comment-meta">
<?php
comment_date();
?>
at <?php
comment_time();
?>
</p>
<div class="comment-content">
<?php
if ($comment->comment_approved == '0') {
?>
<em><?php
_e('Your comment is awaiting moderation.');
?>
</em><br />
<?php
}
?>
<?php
comment_text();
?>
<div class="alignleft"><?php
edit_comment_link(__('(Edit)'), ' ', '');
?>
</div>
</div>
<div class="reply">
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
<div class="cl"> </div>
</div>
<?php
}
示例15: start_el
function start_el(&$output, $comment, $depth, $args, $id = 0)
{
$depth++;
$GLOBALS['comment_depth'] = $depth;
$GLOBALS['comment'] = $comment;
if (!empty($args['callback'])) {
call_user_func($args['callback'], $comment, $args, $depth);
return;
}
extract($args, EXTR_SKIP);
?>
<li <?php
comment_class('media comment-' . get_comment_ID());
?>
>
<?php
echo get_avatar($comment, $size = '64');
?>
<div class="media-body">
<h4 class="media-heading"><?php
echo get_comment_author_link();
?>
</h4>
<time datetime="<?php
echo comment_date('c');
?>
"><a href="<?php
echo htmlspecialchars(get_comment_link($comment->comment_ID));
?>
"><?php
printf(__('%1$s', 'roots'), get_comment_date(), get_comment_time());
?>
</a></time>
<?php
edit_comment_link(__('(Edit)', 'roots'), '', '');
?>
<?php
if ($comment->comment_approved == '0') {
?>
<div class="alert">
<?php
_e('Your comment is awaiting moderation.', 'roots');
?>
</div>
<?php
}
?>
<?php
comment_text();
?>
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
<?php
}