File: /var/www/panigaletech.com/wp-content/themes/panigale/single-news.php
<?php
/**
* The template for displaying all single posts and attachments
*
* @package WordPress
* @subpackage Twenty_Sixteen
* @since Twenty Sixteen 1.0
*/
get_header(); ?>
<?php while ( have_posts() ) : the_post();
$news_id = get_the_id();
$newssDetails=get_post($news_id);
$postedDate = get_field( "news_date", $news_id );
$postedBy = $newssDetails->post_author;
$feat_image = wp_get_attachment_url( get_post_thumbnail_id($news_id) );
// echo "<pre>";
// print_r($newssDetails);
?>
<!--FInd Talent-->
<section class="inner-section mb-3">
<div class="container-fluid">
<div class="row">
<div class="col-lg-8 offset-lg-2 mt-5">
<div class="row">
<div class="col-lg-12">
<div class="news-post">
<div class="post-thumb">
<a href="#"><img class="img-fulid" src="<?php echo $feat_image; ?>" alt="<?php echo $newssDetails->post_title; ?>"></a>
<div class="hover-wrap">
</div>
</div>
<div class="post-content">
<h3 class="heading03 text-blue post-title wow fadeInUp" data-wow-duration="2s"><?php echo $newssDetails->post_title; ?></h3>
<div class="meta wow fadeInUp" data-wow-duration="2s">
<span class="meta-part"><i class="fas fa-user"></i> By <?php the_author_meta( 'display_name', $postedBy ); ?></span>
<span class="meta-part"><i class="far fa-calendar-alt"></i> <?php echo $postedDate; ?></span>
</div>
<div class="news-content">
<?php echo $newssDetails->post_content; ?>
</div>
</div>
</div>
</div>
<?php include 'template-parts/footer-upper-content.php';?>
</div>
</div>
</div>
</div>
</section>
<!--FInd Talent-->
<?php endwhile; ?>
<?php get_footer(); ?>