Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Problems if conditional statements.

Quote Reply
Problems if conditional statements.
Hi,

In the template 'include_rightsidebar.html', I am checking to see what the current page is by using the variable: page_id.

When I do something simple like this: <% page_id %> ... it prints out the current page properly.

But (for some reason,) when I try to use an 'if' statement, it does not work:


<% if page_id == "home" %>

print page specific stuff ...

<% endif %>

Any ideas why the conditional is not working?

Thanks,

K
Quote Reply
Re: [kajukenbokid] Problems if conditional statements. In reply to
Found the answer, the syntax is:

<% if page_id eq home %>