Site logo

[Resolved] Button can’t link to the URL in custom field

Home Forums Support [Resolved] Button can’t link to the URL in custom field

Home Forums Support Button can’t link to the URL in custom field

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #2471565
    Minhaz

    My objective was to add a link to a button in post template – dynamically from posts. To this end, I installed ACF and created a field, labeled it ‘check price’ and set the field type to ‘URL’. My post is showing this field. But when I tried to dynamically retrieve this link to the button in Post Template within the query loop, the Link Source under ‘dynamic data’ does NOT show the ACF field name which is ‘check price’. So, my button does not know what I want it to link to.

    Am I missing something?

    #2471866
    Ying
    Staff
    Customer Support

    Hi Minhaz,

    In order to make the field name show, you need to set the Show in REST API to true.
    For more info: https://www.advancedcustomfields.com/resources/wp-rest-api-integration/#enabling-the-rest-api-for-your-acf-fields

    But even if it’s not shown, you can enter the field name directly in GB’s dynamic data field.

    #2471879
    Minhaz

    I just set the Show in REST API to true. The field name is still not showing in the “Link Source” of button dynamic data

    #2471896
    Ying
    Staff
    Customer Support

    It might take a while, but anyway you can directly enter the custom field’s name in the dynamic data, it doesn’t matter if it shows or not in the dropdown list, as long as the field’s name is correct, the dynamic data should be able to pull the value.

    #2471899
    Minhaz

    I can see no way to enter the custom field’s name in the dynamic data

    #2471923
    Ying
    Staff
    Customer Support

    You can type the post meta name directly in thePOST META FIELD field, then hit the enter key (returnbutton on your keyboard).

    #2471948
    Minhaz

    Yes, it’s working now. Thanks 🙂

    #2474032
    Ying
    Staff
    Customer Support

    No Problem, glad to help 🙂

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.