本文整理汇总了PHP中comment_reply_link函数的典型用法代码示例。如果您正苦于以下问题:PHP comment_reply_link函数的具体用法?PHP comment_reply_link怎么用?PHP comment_reply_link使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了comment_reply_link函数的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: 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
}
示例3: theme_comments
function theme_comments($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li <?php
comment_class();
?>
id="li-comment-<?php
comment_ID();
?>
">
<div class="mk-single-comment" id="comment-<?php
comment_ID();
?>
">
<div class="gravatar"><?php
echo get_avatar($comment, $size = '45', $default = '');
?>
</div>
<div class="comment-meta">
<?php
printf('<span class="comment-author">%s</span>', get_comment_author_link());
?>
<?php
edit_comment_link('', '', '');
?>
<time class="comment-time"><?php
echo get_comment_date();
?>
</time>
</div>
<span class="comment-reply">
<?php
comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</span>
<div class="clearboth"></div>
<div class="comment-content">
<?php
comment_text();
?>
<?php
if ($comment->comment_approved == '0') {
?>
<span class="unapproved"><?php
_e('Your comment is awaiting moderation.', 'mk_framework');
?>
</span>
<?php
}
?>
<div class="clearboth"></div>
</div>
</div>
<?php
}
示例4: 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
}
示例5: replyLink
private function replyLink($args, $depth)
{
$reply_link = '<p class="reply">';
$reply_link .= comment_reply_link(array_merge($args, ['add_below' => 'comment', 'depth' => $depth, 'reply_text' => __('Reply', 'elr'), 'max_depth' => $args['max_depth']]));
$reply_link .= '</p>';
return $reply_link;
}
示例6: secret_comment
function secret_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
?>
<li class="list-group-item" id="li-comment-<?php
comment_ID();
?>
">
<div class="media container">
<div class="media-left">
<?php
if (function_exists('get_avatar') && get_option('show_avatars')) {
echo get_avatar($comment, 48);
}
?>
</div>
<div class="media-body">
<div class="row" id="comment-<?php
comment_ID();
?>
">
<div class="col-md-4">
<?php
printf(__('<cite class="author_name">%s</cite>'), get_comment_author_link());
?>
<?php
edit_comment_link('修改');
?>
</div>
<div class="col-md-4">
发表于:<?php
echo get_comment_time('Y-m-d H:i');
?>
</div>
</div>
<div class="row">
<div class="col-md-8">
<?php
if ($comment->comment_approved == '0') {
?>
<em>你的评论正在审核,稍后会显示出来!</em><br />
<?php
}
?>
<?php
comment_text();
?>
</div>
</div>
</div>
<div class="row">
<?php
comment_reply_link(array_merge($args, array('reply_text' => '回复', 'depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
</div>
<?php
}
示例7: 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">
<?php
echo get_avatar($comment, $size = '40');
?>
<?php
/* printf(__('<cite class="fn">%s</cite> <span class="says">says:</span>'), get_comment_author_link()) */
?>
<cite class="fn"><?php
comment_author_link();
?>
</cite>
<span class="comment-meta commentmetadata"><a href="<?php
echo htmlspecialchars(get_comment_link($comment->comment_ID));
?>
"><?php
printf(__('%1$s at %2$s'), get_comment_date(), get_comment_time());
?>
</a><?php
edit_comment_link(__('(Edit)'), ' ', '');
?>
</span>
</div>
<?php
if ($comment->comment_approved == '0') {
?>
<em class="approved"><?php
_e('Your comment is awaiting moderation.');
?>
</em>
<br />
<?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
}
示例8: ks_list_comments
function ks_list_comments($comment, $args, $depth)
{
global $ks_settings;
$GLOBALS['comment'] = $comment;
extract($args, EXTR_SKIP);
?>
<dt><a name="comment-<?php
comment_ID();
?>
"><?php
if (!ks_option('ks_separate_comments')) {
?>
<font size="-1" color="<?php
echo $ks_settings['comment_color'];
?>
">[<?php
comment_type(_x('Comment', 'noun'), __('Trackback'), __('Pingback'));
?>
]</font><?php
}
?>
</a> <?php
ks_comment_content();
$html = array();
comment_reply_link(array_merge(array('before' => '<div>', 'after' => '</div>', 'reply_before' => '', 'reply_text' => '<img localsrc="149" alt="" />' . __('Reply'), 'login_text' => '<img localsrc="120" alt="" />' . __('Log in to Reply')), $args, array('depth' => $depth, 'max_depth' => $args['max_depth'])));
}
示例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: garland_comment
function garland_comment($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
extract($args, EXTR_SKIP);
?>
<li <?php
comment_class(empty($args['has_children']) ? '' : 'parent');
?>
id="comment-<?php
comment_ID();
?>
">
<div id="div-comment-<?php
comment_ID();
?>
">
<span class="comment-author vcard">
<?php
if ($args['avatar_size'] != 0) {
echo get_avatar($comment, $args['avatar_size']);
}
?>
<?php
printf(__('<cite class="fn">%s</cite> Says:', 'kubrick'), get_comment_author_link());
?>
</span>
<?php
if ($comment->comment_approved == '0') {
?>
<em><?php
_e('Your comment is awaiting moderation.', 'kubrick');
?>
</em>
<?php
}
?>
<br />
<small class="comment-meta commentmetadata"><a href="#comment-<?php
comment_ID();
?>
" title=""><?php
printf(__('%1$s at %2$s', 'kubrick'), get_comment_date(), get_comment_time());
?>
</a> <?php
edit_comment_link(__('edit', 'kubrick'), ' ', '');
?>
</small>
<?php
comment_text();
?>
<div class="reply">
<?php
comment_reply_link(array_merge($args, array('add_below' => 'div-comment', 'depth' => $depth, 'max_depth' => $args['max_depth'])));
?>
</div>
</div>
<?php
}
示例11: 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
}
示例12: 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
}
示例13: sf_custom_comments
function sf_custom_comments($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
$GLOBALS['comment_depth'] = $depth;
?>
<li id="comment-<?php
comment_ID();
?>
" <?php
comment_class('clearfix');
?>
>
<div class="comment-wrap clearfix">
<div class="comment-avatar">
<?php
if (function_exists('get_avatar')) {
echo get_avatar($comment, '100');
}
?>
<?php
if ($comment->comment_author_email == get_the_author_meta('email')) {
?>
<span class="tooltip"><?php
_e("Author", "swiftframework");
?>
<span class="arrow"></span></span>
<?php
}
?>
</div>
<div class="comment-content">
<div class="comment-meta">
<?php
printf('<span class="comment-author">%1$s</span> <span class="comment-date">%2$s</span>', get_comment_author_link(), human_time_diff(get_comment_time('U'), current_time('timestamp')) . ' ' . __("ago", "swiftframework"));
?>
<div class="comment-meta-actions">
<?php
edit_comment_link(__('Edit', 'swiftframework'), '<span class="edit-link">', '</span><span class="meta-sep"> |</span>');
?>
<?php
if ($args['type'] == 'all' || get_comment_type() == 'comment') {
comment_reply_link(array_merge($args, array('reply_text' => __('Reply', 'swiftframework'), 'login_text' => __('Log in to reply.', 'swiftframework'), 'depth' => $depth, 'before' => '<span class="comment-reply">', 'after' => '</span>')));
}
?>
</div>
</div>
<?php
if ($comment->comment_approved == '0') {
_e("\t\t\t\t\t<span class='unapproved'>Your comment is awaiting moderation.</span>\n", 'swiftframework');
}
?>
<div class="comment-body">
<?php
comment_text();
?>
</div>
</div>
</div>
<?php
}
示例14: 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
}
示例15: 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 } ?>