I’m trying to add a fairly complex conditional to my template, and the results are unpredictable. As best I can tell, if the conditional is too long, the entire {exp:weblog:entries} tag that contains it fails to execute.
I pasted the conditional here, and added line feeds for readability. (It’s a shame I can’t have those line feeds in my actual source code.)
As soon as I added the code between the >>> and <<<, the conditional stopped working.
If there’s a way to refactor this or rewrite it in PHP, I’d really appreciate a hand. (I don’t know how to access EE variables in PHP, or I’d try that.)
Thanks in advance!
{exp:weblog:entries status="top menu|main menu|open" show_future_entries="yes" disable="categories|member_data|pagination|trackbacks|comments"}
... hello world! This line won't show if the conditional is too long.
{if (>>>weblog_short_name!="board-minutes" AND <<<weblog_short_name!="board-only" AND weblog_short_name!="providers-only" AND weblog_short_name!="staff-only")
OR ((member_group==1 OR member_group==5 OR member_group==7))
OR (>>>(weblog_short_name=="board-minutes" AND member_group==6)<<<
OR (weblog_short_name=="board-only" AND member_group==6)
OR (weblog_short_name=="providers-only" AND member_group==9)
OR (weblog_short_name=="staff-only" AND member_group==8))}
... show body text of page
{if:else}
... not logged in or unauthorized
{/if}
{/exp:weblog:entries}[Mod Edit: Moved to the Technical Support forum]