ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Conditional Statement Member ID and Custom Field using Stash

December 20, 2012 11:47am

Subscribe [2]
  • #1 / Dec 20, 2012 11:47am

    Phil Ecker

    78 posts

    Have an issue with my conditonal statement below.

    If my custom field is equal to the member logged in it displays the link, but if any other member_id is logged in it doesn’t display, really hoping someone can tell me what I am doing incorrectly.

    {if member_id == '79' OR member_id == '113' OR member_id == '129' OR member_id == '130' OR member_id == '132' OR idea_project_leader == '{exp:stash:get name="projectleader"}'}<a href="/banking-simplified/update/{entry_id}/">{/if}{idea_project_year}-{idea_project_number}{if member_id == '79' OR member_id == '113' OR member_id == '129' OR member_id == '130' OR member_id == '132' OR idea_project_leader == '{exp:stash:get name="projectleader"}'}</a>{/if}

     

  • #2 / Dec 20, 2012 11:50am

    Have you tried using {logged_in_member_id}? That’s usually the ticket in this situation.

  • #3 / Dec 20, 2012 12:59pm

    Phil Ecker

    78 posts

    Thanks Christopher! That was my issue… Would I be safe to assume that wrapping that with the following would have worked as well?

    {if logged_in}{/if}
.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases