March 20th, 2003, 08:01 PM
trim var problems...my brain has left me
Ok... I cant for the life of me think of how to set this up
<a href="<%=subNavUrl%>" class="subNavLink"><%=LCASE( Replace( pageTitle, "_", " " ) )%></a> :
so that the : is not display at the end of the last item in the list. My links are called from a sub, but thats not relevant to this question. A link is as follows:
<%WriteSubNav "/home/home.asp", "newsfeeds", "view our newsfeeds from around the world"%>
any help appreciated.
March 23rd, 2003, 12:14 AM
passing a boolean parameter to define if the : should be written or not seems like a simple solution.
If there is no way for you to find out when is the call going to be the last one, you could reverse it, so you would only have to worry about finding out when is the call going to be for the first one,
instead of writing
make it write
except for the first one where you write
I hope this is of any help.
March 23rd, 2003, 03:41 AM
putting it in front of the first one would be much easier as I cant really determine how many there are using the string I have at the moment.
How do I determine the first.
<% if num >1 the
does not work as obviously there is no num var...
March 23rd, 2003, 05:47 PM
At the begining of the page create a variable ..
probably boolean ...
set it to False
and when you are writing the link check if the variable is true or false ..
if it is true, write the : at the begining
if it is false don't write the :
and after the write, set the variable to true, so the very first write will find the variable false and the rest will find it true.
I hope this is of nay help.