Custom Fields
Re-Envisioned
Support MB Views Conditional Display rule

  • Creator
    Topic
  • #31458
    Ole Poetter
    Participant

    Hi,

    in MB Views we can set a location rule to display the template (for example we can define that the template is only display on a single of a custom post type).

    I ther a way to define also a user base logic so we can archive somthing like this:

    "Show View only on single of ctp ="cars" but only if "current user" = "post author"?

    Kind regards,
    Ole

Viewing 1 replies (of 1 total)
  • Author
    Replies
  • #31463
    Long Nguyen
    Moderator

    Hi Ole,

    There is no option to show View if the post author is the current user. You can create a condition to check the user and show a template, otherwise, show another template.

    {% if (check current user) %}
        show template A
    {% else %}
        show template B or redirect to a page
    {% endif %}
Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.