I’m trying to figure out how to change the entry_id based on a conditional. The below only shows the first condition “33” in all instances. What am I doing wrong?
{if "{segment_1}"=="es"}
{assign_variable:post_lang="33"}
{if:elseif "{segment_1}"=="pt"}
{assign_variable:post_lang="34"}
{if:else}
{assign_variable:post_lang="32"}
{/if}
{exp:weblog:entries weblog="home" entry_id="{post_lang}" limit="1" dynamic="off"}
<h3>{title} {post_lang}</h3>
<p> {page_content}<br />
{/exp:weblog:entries}