WordPress.org

Support

Custom Fields

  • Hi Guys,

    These custom fields puzzle me. WordPress puts them in their software but makes it impossible to display them on the actual web page!

    I have thrawled everywhere for a simple ‘how-to’ to get these displaying on the website.

    Could anyone share a simple explaination for this please. I would really appreciate it.

    Many thanks

    PG

Viewing 3 replies - 1 through 3 (of 3 total)
  • esmi

    @esmi

    Forum Moderator

    Hi Esmi,

    Thanks a million for that. I have been ‘trying’ to follow that ‘how-to’ page but I’ve been really struggling. I am puzzled as to where I am supposed to put that code.

    Also, If I create new custom fields, does this mean that I have to make some new code? I am just working with the standard WordPress template at the moment.

    Many thanks

    PG

    esmi

    @esmi

    Forum Moderator

    Using that page’s example, you’d need to add <?php the_meta(); ?> to the relevant template file. That would index.php if you want these fields on the front page of your blog, single.php for a single post etc.

    You don’t need to add any extra code to create custom fields. WP does all that for you. You just need to add code to the various template files to get your new fields to display or to be able to “do stuff” with them.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Custom Fields’ is closed to new replies.
Skip to toolbar