Re: Active link problem driving me nuts!!! -
07-11-2003
, 11:38 AM
Hi Fran,
If I've understood you correctly, the reason your previously active
link loses it's colour, is because it is loosing focus when you click
on the DIV or SPAN, and hence is no longer the active item, even
though your content may not have changed. I think you'll need to try
something other than using CSS psuedo classes (:active, :link etc.) to
drive colours. It sounds like what you're essentially asking is that
the highlighted link is tied directly to the currently displayed
content. If you're using frames, you could maybe do something like...
<a href="#" style="color:expression(parent.content.location.hr ef.indexOf('productA')!=-1
? 'green' : 'blue')">Product A</a>
....but this relys on you being able to identify a unique string in the
HREF of each page, it will only work in IE5+ and it could add quite a
lot of weight to the page, so without more info on your set up and
audience I can't say if this will definitely work.
You could also make each content frame set the colour of it's
corresponding HREF.
I would imagine there are lot of other ways too, but I just don't
think you can rely on A.active psuedo class, and you'll need to try
something different.
HTH
Russ. |