You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@forrest.apache.org by Clay Leeds <cl...@medata.com> on 2004/11/19 17:15:00 UTC

Using CSS to display/hide subnav links (was Re: slightly different navigation)

This thread has been moved to dev@forrest.apache.org...

On Nov 19, 2004, at 4:42 AM, Ross Gardler wrote:
> Clay Leeds wrote:
>> On Nov 18, 2004, at 3:50 PM, THOMAS BENOIT wrote:
>>> De: Ross Gardler <rg...@apache.org>
>>>
>>>> Would it suit you if there was no collapsing menu at all?
>> It would suit my needs for some sites (particularly where I have 
>> fewer pages). It wouldn't be good for the FOP web site, but for web 
>> sites which have smaller documentation needs it would be great!
>>> I need a 2 or 3 level menu. So the collapsing menu suits well, 
>>> excepts
>>> for the problem described above.
>>> Too bad the tree menu is controlled by a javascript script.
>>> Has someone made some modifications to the basic skins so that we are
>>> not restricted by a simple javascript collapsing menu (I think some
>>> modification to the XSLT files should do the trick). The idea is not 
>>> to
>>> have to click twice to display the intro text of a category.
>>>
>>> Thank you for your help,
>>>
>>> Thomas
>> I would be prefer it be done in CSS, if possible (i.e., without 
>> javascript).
>
> Patches from either of you would be great :-) (can this be done with 
> Javascript, I'd love to see that solution)
>
> Ross

I seem to remember something that would show/hide via click, but 
perhaps it was :hover. By hovering over the 'heading', one could 
certainly show a nested sub-div (similar to a DHTML menu)... Would that 
be 'interesting' for anyone?

Taking a page out of Eric Meyer's 'book':
http://www.meyerweb.com/eric/css/edge/popups/demo.html

For example, take the Related Projects 'section' of the Forrest home 
page. I'm thinking along the lines of:

#menu_1.2 {
   display: none;
}

And then either do a pop-out menu to the right:
#menu_1.2Title:hover #menu_1.2 {
   display: block;
   left: 150px
}

...or do a pop-out menu in the current location:
#menu_1.2Title:hover #menu_1.2 {
   display: block;
}

We'd still need to come up with a solution to identifying (in the 
siteNav) when someone is on the page

Web Maestro Clay
-- 
Clay Leeds - <cl...@medata.com>
Webmaster/Developer - Medata, Inc. - <http://www.medata.com/>
PGP Public Key: <https://mail.medata.com/pgp/cleeds.asc>


Re: Using CSS to display/hide subnav links (was Re: slightly different navigation)

Posted by Web Maestro Clay <we...@mac.com>.
On Nov 19, 2004, at 8:15 AM, Clay Leeds wrote:
> I seem to remember something that would show/hide via click, but 
> perhaps it was :hover. By hovering over the 'heading', one could 
> certainly show a nested sub-div (similar to a DHTML menu)... Would 
> that be 'interesting' for anyone?
>
> Taking a page out of Eric Meyer's 'book':
> http://www.meyerweb.com/eric/css/edge/popups/demo.html
>
> For example, take the Related Projects 'section' of the Forrest home 
> page. I'm thinking along the lines of:
>
> #menu_1.2 {
>   display: none;
> }
>
> And then either do a pop-out menu to the right:
> #menu_1.2Title:hover #menu_1.2 {
>   display: block;
>   left: 150px
> }
>
> ...or do a pop-out menu in the current location:
> #menu_1.2Title:hover #menu_1.2 {
>   display: block;
> }
>
> We'd still need to come up with a solution to identifying (in the 
> siteNav) when someone is on the page

...to continue on that line of thought, as part of the transformation 
process, I think forrest needs to identify the 'selected' page (it 
appears to do this now, but I don't know how... could someone point me 
in the right direction for this).

BTW, one 'nice' feature (?) of the current "click to hide/show" 
navigation system is that it apparently defaults to OPEN if Javascript 
is turned off (nice work, Thorsten--at least I think that's your 
handiwork). I definitely prefer to be able to see all the links, all 
the time, so I want to make this permanent for the FOP site. No sense 
hiding the navigation from everyone IMO...

Unfortunately, I don't know how to PATCH it so the getmenu.js 
javascript file isn't loaded or I'd provide a PATCH. As I mentioned 
before, configurability of this menu hide/show would be nice to add to 
skinconf.xml, and I would recommend the default is to *not* load 
skin/getmenu.js.

As for the CSS-based 'pop-out' menu system I described in my previous 
POST, that is something I could spend some time on. I'll give it some 
thought now that I have erm... more free time.

Web Maestro Clay
-- 
<we...@mac.com> - <http://homepage.mac.com/webmaestro>
My religion is simple. My religion is kindness.
- HH The 14th Dalai Lama of Tibet