• Hello, i’m a ACF beginner and trying to implement the ACF values in my site. I created the field group “fieldgroupx” with the fields “fieldvalue1” and “fieldvalue2”. I’ve implemented the fields in a portfolio page (Go Portfolio/Portfolio Post Type) and it works. I can see the fields and enter some text.

    But i don’t know how to show the custom field values. How do i show the field values on a the page and the portfolio page?

    https://www.ads-software.com/plugins/advanced-custom-fields/

Viewing 2 replies - 1 through 2 (of 2 total)
  • just put the following php code in your page template file.

    if(get_field('fieldvalue1') ) {  // check if field is populated
    
    the_field('fieldvalue1'); // echo the field value
    echo '<p>'.get_field('fieldvalue1')'.</p>'; // or echo the field value with some html
    
    }
    Thread Starter redvega

    (@redvega)

    Thank you very much! Can you explain what the “echo” thing does? I’m new to this ??

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to show the field value/content on a page?’ is closed to new replies.