Post Field get ID

Support Meta Box AIO Post Field get ID

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #50088
    Ron PhillipsRon Phillips
    Participant

    Hi,

    I have the most current MB AIO. I want to connect a post to a product to get cart information to place on the post. I am using the POST field which in Bricks does return the product title and link, but I want the product ID to plug it into the cart.

    How do I return just the ID?

    Thank you.

    -Ron

    #50089
    PeterPeter
    Moderator

    Hello Ron,

    Thanks for reaching out.

    If you use Meta Box helper function $post_id = rwmb_meta( 'post_field_id' ); it will return the post ID by default. Maybe the Bricks builder filters the value and returns the title and link for displaying in the frontend.

    Following the documentation https://docs.metabox.io/fields/post/#data

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