WordPress.org

Support

Support » Plugins and Hacks » [Resolved] [Advanced Custom Fields] get_field working in page.php but not in page-template

[Resolved] [Advanced Custom Fields] get_field working in page.php but not in page-template

  • <?php wp_nav_menu( array( 'menu' => get_field( 'menuname'), 'container_class' => 'side-menu' ) ); ?>

    This line is working perfectly in any page.php and single.php … however when I put it in for example customtemplateWide.php in the page-templates folder the result is a side-menu but not the one defined in the ‘menuname’ field …

    Now I was wondering if this could be a because it is a page-template that is used … otherwise I have no clue why it would work in some pages and not in others … .

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘[Resolved] [Advanced Custom Fields] get_field working in page.php but not in page-template’ is closed to new replies.
Skip to toolbar