7862 Posts in 2032 Topics by 1135 members
Jump to:If this is your first visit, you will need to register before you can post. However, you can browse all messages below.
| Page: 1 | go to end | Reply | |
| Author | Topic: if with or, or somethings else ;-) | 337 views |

12 May 2008 at 5:50am
Hello @all!
I have a simple menu, but I wanted to have some spaces between at some positions.
like:
***********
Home
<br />
Contact
Impress
<br />
News
***********
So, I have to inklude:
<% if Pos = 2 %>
<li style="height: 5px;"> </li>
<% end_if %>
But for the secound spacer I wouldn't like to write:
<% if Pos = 4 %>
<li style="height: 5px;"> </li>
<% end_if %>
How can I made this with only one if-statement?
<% if Pos = 2 || Pos = 4 %>
<% if (Pos = 2) || (Pos = 4) %>
<% if Pos = 2 or Pos = 4 %>
<% if (Pos = 2) or (Pos = 4) %>
has the only effect that the site will be blank. ;-)
Last edited: 16 May 2008 at 1:51am

16 May 2008 at 11:04am
Are the breaks determined by the menu items themselves or just the position? If its the menu items, you could add a new field to the relevant page type called 'MenuSpace', then use the value of that field in your if statement to decide whether to insert a space above the item.
cheers
bruce

16 May 2008 at 7:03pm
Thanx, for this idea.
I will try to do so ;-)
| 337 views | |||
| go to top | Reply |