I found this: $readinglist = $post_meta_cache[256][‘reading’];
on http://codex.wordpress.org/Using_Custom_Fields but don’t quite understand it.
Where do the php tags go? For me would it be:
$price = $post_meta_cache[$post->ID][‘price’]
Please advise. I’m just trying to display the Price from my custom “price” field.
Thanks,
Jon
I tried this:
<?php $key=”price”; echo get_post_meta($post->ID, $key, true); ?>
but it doesn’t seem to work!
Try the plugin Get Custom Field Values
It just makes it easier, and explains a simple line of plugin-code to put in
http://wordpress.org/extend/plugins/get-custom-field-values/
also read
http://coffee2code.com/wp-plugins/get-custom-field-values/
If you’d be ok with showing ALL your custom fields on that post (not just “price” but also “color” or whatever), try the_meta template tag:
<?php the_meta(); ?>
http://codex.wordpress.org/Template_Tags/the_meta
Hope this helps!
Actually, it was a simple oversight, I forgot to capitalize “Price”.
Thanks for the help!