0

Is it possible to do something like the following (which doesn't work).

{if layout:contents}
    {layout:contents}
{if:else}
    404!
{/if}

thanks!

:: ed

1 Answer 1

0

{layout:contents} is no regular layout variable (it will always contain the entire contents of the template in which the {layout="template_group/template"} tag appeared), which is why I suspect your code sample doesn't work.

But all other layout variables should work just fine as conditionals, as in your code sample.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.