php - Wordpress echoing a certain custom field -


I am trying to resize a specific custom field called 'price'.

I have tried

  & lt ;? Php echo get_post_meta ($ post-> ID, 'value', true); ? & Gt;  

How can I resonate the value area?

You must first get information about Wordpress's current term in a variable, for its use Can:

  global $ post;  

This variable will receive all the post information in $ post .

With this you can call your function and it should work:

  echo get_post_meta ($ post-> ID, 'value', true) ;  

but value should have a meta property for that post.


Comments

Popular posts from this blog

import - Python ImportError: No module named wmi -

Editing Python Class in Shell and SQLAlchemy -

lua - HowTo create a fuel bar -