Support

Account

Home Forums General Issues Help retrieving with ACF to define posts shown – Using a Shortcode Reply To: Help retrieving with ACF to define posts shown – Using a Shortcode

  • Hi John

    Is there another way I can demo this to test the fields? I also can’t see a reason the fields would not work.

    The code works 100% when the ACF parameters are not set – I can use the shortcode with the custom post type specified and it returns the correct information just fine.

    [list-posts type="company_directory" posts_per_page="40" posts="40"]

    This displays all the posts of the type company directory.

    I just then wanted to query what is shown based on the field option within that post type?

    I based this code from an article online about creating flexible shortcodes in WordPress.