Custom fields and post meta for single posts
-
For 2 days I’ve been trying to get custom fields to appear correctly.
In index file, this: <?php the_meta(); ?> works to display the custom field. However, it doesn’t show up on any single posts. Have tried single.php and function.php about 60 times, using:
<?php echo get_post_meta($post->ID,'Dark_Thoughts', true); ?> <?php echo get_post_meta(get_the_ID(),'Dark_Thoughts', true); ?> <?php echo types_render_field("Dark_Thoughts", array('output'=>'html')); ?> <?php echo c2c_get_current_custom('dark_thoughts'); ?>">
I’ve found these codes in the forum or in the Codex. None of them work in many variations, and I’ve tried them in many places in the single.php. Can someone look at this with fresh eyes and please help me out?
Here’s what it looks like on index page. As you can see, custom field not appearing on any single post. https://chocolatecartoons.com/
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Custom fields and post meta for single posts’ is closed to new replies.