Thanks, but i cant get it….
<?php
get_header(); ?>
<div id="single_page_wrap" class="clearfix">
<div class="container">
<div class="row">
<?php while (have_posts()) : the_post();?>
<div class="col-md-8 col-sm-8 single_page_content">
<div class="single_title_image clearfix">
<h1><?php the_title(); ?></h1>
<?php the_post_thumbnail('full'); ?>
</div>
<!--single_title_image clearfix-->
<div class="single_content_text clearfix">
<?php
the_content();
?>
//start stern data
add_filter( 'the_content', 'featured_image_before_content' );
function featured_image_before_content( $content ) {
$post_to_get = 6461; // change to your target post
if ( get_the_ID() == $post_to_get ) {
return $content;
}
if ( is_singular('post') {
$add_post = get_post( $post_to_get );
$addl_content = $addl_post->post_content;
$addl_content = apply_filters( 'the_content', $addl_content );
$thumbnail = get_the_post_thumbnail( $addl_post);
$content = $thumbnail . $addl_content;
}
return $content;
}
// end of stern data
</div>
<!--clearfix-->
</div>
<!--col-md-8 single_page_content-->
<?php endwhile; ?>
<?php wp_reset_query(); ?>
<div class="col-md-4 col-sm-4 single_wid_wrap">
<?php get_sidebar('post') ?>
</div>
<!--col-md-4 single_wid_wrap-->
</div>
<!--row-->
</div>
<!--container-->
</div><!--single_page_wrap-->
<?php get_footer(); ?>
Cant see post 6461 under my post. The code shows as text inside the content. I attach single.php for input,