I am trying to display some content on the first page of my site. But I don’t want to display it on the 2nd, 3rd, ... pages.
I am using segments to achieve this, but for some reason it is not working.
Basically I am checking if segment_1 exists. If the value is nothing, then I am probably still on the first page and I can display the content. If the value is P0, then I am still on the first page, and I can display the content.
This is the code, that I am using.
{if segment_1 == "" OR segment_1 == " " OR segment_1 == "P0"}
content
{/if}My problem is, that for some reason, the content still shows up on all the other pages (2nd, 3rd, etc.).
I narrowed down the problem to the first section of the condition:
segment_1 == ""If I remove this, the content is not displayed on the 2nd, 3rd, etc. pages. But it is also missing from the 1st page. If I add the condition back, the content appears on the 1st page, but it also appears on the other ones.
Any ideas on what I might be doing wrong? Or is there a better way to do this?
Thanks!