How can I retrieve value from a radio field in MB Field?

Support MB Views How can I retrieve value from a radio field in MB Field?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #34451
    info@ceescoenen.nl[email protected]
    Participant

    This doesn't work : {{ post.re_waardering.value }}
    {% set args = { post_type: 'review', posts_per_page: 10 } %}
    {% set posts = mb.get_posts( args ) %}
    {% for post in posts %}
    /* This doesn't work /
    Field {{ post.re_waardering.value }}
    /* This work */
    RWMB: {{ mb.rwmb_meta( 're_waardering','', post.ID ) }}

    #34471
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Please use the helper function rwmb_meta() to get the field value in the custom query. As I wrote down in the documentation, if you use a custom query, the field in the Insert Field tab will not work as designed.
    https://docs.metabox.io/extensions/mb-views/#main-query

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