Welcome Guest, Not a member yet? Register   Sign In
Include a menu on every page? use url helper in a class?
#17

[eluser]John_Betong[/eluser]
[quote author="NateL" date="1257016152"]I'm not passing it into the anchor. It's a part of my list item.

Code:
<li class="active"><a href="/about">about</a></li>
is what I'm trying to accomplish.

Quote:Your $toggle is being populated with the correct values but it is not being passed to the anchor parameter.

No - unfortunately it isn't.

Even if I did put $toggle in as a parameter for the anchor, it would still show "off".

If I remove this line of code:
Code:
echo '>>>' .$this->uri->uri_string .'<<<';

I get this:
>>>off<<<>>>off<<<>>>off<<<>>>off<<<

That's 4 menu items, and 4 instances of "off". It *should* be:

>>>off<<<>>>active<<<>>>off<<<>>>off<<<[/quote]
&nbsp;
I think that it is the anchor that requires the class toggle to change color and not the link.
&nbsp;
It has been a long day for me and the recent beers does not help so may I suggest that you send the relevant parts of your CSS file and the links that you want to include in your menu and tomorrow I will supply a working example. The example will be online and I will supply the code. I think this is the only way that we will not be at cross-purposes.
&nbsp;
&nbsp;
&nbsp;
edit: spelling - must get a better keyboard Smile


Messages In This Thread
Include a menu on every page? use url helper in a class? - by El Forum - 10-31-2009, 08:55 AM



Theme © iAndrew 2016 - Forum software by © MyBB