JSFiddle - React, Tailwind, and code Playground
by rizwanabbasi
HTML
<?php
function img_to_rss($content) {
global $post;
if(has_post_thumbnail($post->ID)) {
$content = '<p>'.get_the_post_thumbnail($post->ID).'</p>' . get_the_content();
}
return $content;
}
add_filter('the_excerpt_rss', 'img_to_rss');
add_filter('the_content_feed', 'img_to_rss');
?>
<?php
add_theme_support('post-thumbnails');
function normalComments($comment, $args, $depth)
{
$GLOBALS['comment'] = $comment;
global $options;
foreach ($options as $value) {
if (get_settings( $value['id'] ) === FALSE) { $$value['id'] = $value['std']; } else { $$value['id'] = get_settings( $value['id'] ); }
}
$adminid = explode (",",$wpzoom_admin_ids);
$oddcomment = 'guest';
$wrappeddate = wordwrap($comment->comment_date, 10,"<br />\n");
if (in_array($comment->user_id, $adminid)) {$oddcomment = 'author'; }
$gravatarsize = $wpzoom_comments_gravatar_size;
$gravatar_id = md5($comment->comment_author_email);
$gravatar = get_avatar($comment->comment_author_email, $gravatarsize,'');
echo"<li class=\"$oddcomment\"><div class=\"gravatar gravatar-$oddcomment\">$gravatar";
if($args['max_depth']!=$depth) { ?>
<div class="reply"><?php comment_reply_link(array_merge($args, array('depth' => $depth, 'max_depth' => $args['max_depth']))) ?></div>
<?php }
echo"</div>";
echo"<div class=\"comment-author\"><cite class=\"$oddcomment\">"; if (strlen($comment->comment_author_url) > 10){ echo"<a href=\"".$comment->comment_author_url."\" rel=\"external,nofollow\">" . $comment->comment_author ."</a>"; } else{ echo $comment->comment_author; } echo"</cite>
<br /><span class=\"datetime\">$wrappeddate</span></div>";
echo"<div class=\"comment-content\" id=\"comment-$comment->comment_ID\">";
echo"<p>".$comment->comment_content."</p>";
if ($comment->comment_approved == '0') :
echo"<em>('Your comment is awaiting moderation.')</em>";
endif;
echo"</div>";
echo"<div class=\"cleaner\"> </div>";
}
function...