[All Adaptavist Apps]

Page tree

Hello

I was trying to highlight the tab indicated the current page (like adaptavist). Does anyone have any experience with it? the a:active in css doesn't work for me.

Thanks a lot

-Phu

  • No labels

7 Comments

  1. Unknown User (gfraser)

    We use the sorted-children macro - it automatically adds a 'custom' class to the link that is currently 'active'.

    Note that :active in CSS means a link that you have clicked that is still loading. Check out http://w3schools.com for more info on CSS.

    1. Unknown User (amoran)

      I think Guy means the 'current' class rather than 'custom'.

      Both {sorted-children} and {list-spaces} are very useful macros for creating navigation elements, you can find more details in the notation guide.

  2. Unknown User (andynguyen)

    Thanks a lot for the info. I appreciate that.

  3. Unknown User (andynguyen)

    Other questions.

    Would you like to show me where to find documentation of sorted-children macro? I could find children macro, but not sorted-children.

    When I try with sorted-children macro, it seems that it automatically add my link to "child page" class rather than "current" class.

    And also, if I want to show the "Home" page too, how should I do it? I have been trying and looking for guidelines but unfortunately, couldn't find any.

    Thanks a lot.

    -Andy

  4. Unknown User (andynguyen)

    Hi Alain,

    I really appreciate your help. I have taken a look at the notation guide and thought if I set the parameter showRoot=true, the homepage would show. This is how I did it

    {sorted-children:@home|showRoot=True|class=menu}
    

    The homepage did appear, however, themebuilder created another unordered list with only one <li>element linked to the homepage. The other links were in another <ul> list.

    Although I set

    {class=menu}

    , theme-builder didn't set the class of my list to "menu". It was still "children current page homepage rootpage."

    A copy of my html structure page is included. Any help will be appreciated.

  5. Unknown User (josedurand)

    Hello,

    I have the same problem, I want highlight the first menu tab when i navigate on the wiki.

    I try to use sorted-children markup but without success...

    I have built the menu like this :

    
    {table:width=100%|cellpadding=0|cellspacing=0|border=0}
    {tr}
    {td:valign=middle}
    {menubar}
    {menu}{menulink:homepage}Home Page{menulink}{menu}
    {menu}TAB 1 
    {compound-menuitem:undercostructionpage|icon=ico.png|caption=ITEM}
    {compound-menuitem:undercostructionpage|icon=ico.png|caption=ITEM}
    {menu}
    {menu}TAB 2 
    {compound-menuitem:undercostructionpage|icon=about|caption=ITEM}
    {compound-menuitem:undercostructionpage|icon=presentation|caption=ITEM}
    {menu}
    {menubar}
    {td}
    {td:align=right|valign=middle}
    {builder-search}
    {td}
    {tr}
    {table}
    
    

    i would like highlight " Home Page ", " TAB 1 ", " TAB 2 " if a user is on the pages

    Thank you for your help,

    JD