Shortcode not working inside posts shown via $queried_post->post_content ?
-
I try to insert the shortcode
[rps-include post=”720″ title=”true” titletag=”h2″ ]
The post in index.php is shown via $queried_post->post_content . This is what is in index.php
<?php
rewind_posts();
$post_id = 264;
$queried_post = get_post($post_id);
echo $queried_post->post_content?>
The shortcode appears without showing the corresponding content and i get the shortcode displayed as normal text but no content.
On a single post from single.php displays the content fine . This is the code in single.php
<?php while (have_posts()) : the_post();
php the_title();
php the_content();?>So, can i get the content shown properly when including shortcode in a single post displayed with $queried_post->post_content ?
Thank you !
- The topic ‘Shortcode not working inside posts shown via $queried_post->post_content ?’ is closed to new replies.