i use a control variable to determine the layout in a page.
similar to the following
{%if page.extra.layout == “top” %}
i test whether the variable exists using the following
{%if page.extra.layout and page.extra.layout == “top” %}
how to test whether a variable is not found.
along the lines of
{%if page.extra.layout == null %}
which fails.