Thread Rating:
  • 1 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
myApp
#8
Thumbs Down 
Hi

I'm pretty new to this cms engine (this weekend)
I like this theme and i'm trying to use it... with I18N pluggin too.

One of the things i'm struggling is with the creation of drop donw menu... i can't get it to work... i made severall tries with solutions i fond here on forum but with no avail... the best i achieved is to show the below the main item the child itens but always visible... Unfortunatly i don't have now the time to go over the code to figure out one solution... there exist some simple solution, css and I18N related, i think ?

TIA

Regards

JL

[EDIT]

Kolyok member was kind enought to gime me a solution for this problem. As it can be useful for someone else i will post here their answer:

---------
Ok i checked the theme and it has no styling for multilevel navigation.
Ill show you a snippet that adds dropdown/multilevel navigation (only for one level depth)

First things first:

Open up the theme's header.inc.php and search for this:
PHP Code:
PHP Code:
<?php get_navigation(return_page_slug()); ?>
and replace it with this:
PHP Code:
PHP Code:
<?php get_i18n_navigation(return_page_slug(), 01I18N_SHOW_MENU); ?>

Now open up the theme's style.css and search for this:
PHP Code:
PHP Code:
#menu ul li {
    
floatleft;
    
padding12px 25px 13px 25px;
    
margin-bottom0px;

and replace/add this:
PHP Code:
PHP Code:
#menu ul li {
    
floatleft;
    
padding12px 25px 13px 25px;
    
margin-bottom0px;
    
positionrelative;
}

#menu ul ul {
    
display:none;
    
position:absolute;
    
margin-top13px;
    
left0;
}

#menu ul li:hover > ul {
    
displayblock;
}

#menu ul ul li {
    
backgroundurl(pics/menubg.png);
    
background-repeatrepeat-x;
    
float:none;
    
z-index:100;
}

#menu ul ul li.current {
    
backgroundurl(pics/menubg.png);
    
background-repeatrepeat-x;
    
float:none;
    
z-index:100;


Now check your menu. It should have multilevel navigation but only for one level depth.
I havent added more levels since i think its better if you practice it a little by yourself so you understand why and how it works :-)

Check/study the above codes and see if you can extend it to get a more complex menu.

------------

A great hug for him, thank you Koliok !
Reply


Messages In This Thread
myApp - by PixelOfficer - 2012-03-26, 09:28:42
myApp - by mikeh - 2012-03-26, 09:51:44
myApp - by PixelOfficer - 2012-03-26, 10:12:39
myApp - by mikeh - 2012-03-26, 13:33:56
myApp - by PixelOfficer - 2012-03-26, 21:06:33
myApp - by didou038 - 2012-03-26, 21:54:21
myApp - by PixelOfficer - 2012-03-27, 22:38:16
RE: myApp - by jlongo - 2013-08-19, 19:51:54



Users browsing this thread: 1 Guest(s)