noiragneau Posted December 5, 2013 Share Posted December 5, 2013 Witam, czy jest możliwość ustawienia indywidualnego tła dla każdej z pozycji menu.Przykładowo: "Strona główna" ma tło zielone, "Oferta" czerwone itd...Myślałem że uda się coś zrobić z poziomu CSSa ale każda pozycja korzysta z tej samej klasy.Może ktoś miał podobny problem? Link to comment Share on other sites More sharing options...
vekia Posted December 5, 2013 Share Posted December 5, 2013 do problemu można podejść na dwa sposoby. modfyikacja blocktopmenu.php, konieczne jest wprowadzenie kodu, który umożliwi zidentyfikowanie konkretnych elementów menu poprzez nadanie unikalnych identyfikatorów. druga opcja: jquery : http://stackoverflow.com/questions/14007074/targeting-second-span-in-li-element Link to comment Share on other sites More sharing options...
Er.Ritesh Posted December 5, 2013 Share Posted December 5, 2013 (edited) you can use if else condition . Edited December 5, 2013 by Er.Ritesh (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted December 5, 2013 Share Posted December 5, 2013 vous pouvez utiliser si la condition d'autre ? Link to comment Share on other sites More sharing options...
noiragneau Posted December 5, 2013 Author Share Posted December 5, 2013 you can use if else condition . in what case? How you can see this? Link to comment Share on other sites More sharing options...
Er.Ritesh Posted December 5, 2013 Share Posted December 5, 2013 blocktopmenu module blocktopmenu.tpl file put condition for background-color. Link to comment Share on other sites More sharing options...
noiragneau Posted December 5, 2013 Author Share Posted December 5, 2013 blocktopmenu module blocktopmenu.tpl file put condition for background-color. I'm begginer in presta - could You describe it more detailed ? I don't know how to put any extra condition. Link to comment Share on other sites More sharing options...
noiragneau Posted December 5, 2013 Author Share Posted December 5, 2013 (edited) I found the solution, probably the easiest : .sf-menu li:first-child {background: yellow !important;} .sf-menu li:nth-child(2) {background: green !important;} More info: http://stackoverflow.com/questions/5664773/how-can-i-get-the-second-child-using-css Thanks for any help Edited December 5, 2013 by noiragneau (see edit history) Link to comment Share on other sites More sharing options...
Er.Ritesh Posted December 5, 2013 Share Posted December 5, 2013 (edited) ok thanx. Edited December 5, 2013 by Er.Ritesh (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted December 5, 2013 Share Posted December 5, 2013 temat zamykam. jak się ogarniecie z językiem to otworzę. Link to comment Share on other sites More sharing options...
Recommended Posts