By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,767 Members | 1,198 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,767 IT Pros & Developers. It's quick & easy.

div inheritance problem

oll3i
100+
P: 679
Expand|Select|Wrap|Line Numbers
  1. echo "<div id=\"vertmenu\">";    
  2. echo    "<ul>";
  3.  
  4.         echo '<li><a href="javascript:void(0)" onclick="drop(\'vert_menu_drop1\')" class=current title=Profil>'.$var143.'</a></li>';
  5.         echo "<div id=\"vert_menu_drop1\" style=\"display: none;width:100px\">";
  6.         echo "<ul>";
  7.         echo '<li><a href="http://exec-jobs.purcon.pl/pracodawca/konto/view.php?language='.$language.'&modul_vert_menu=profile" title=Profil>'.$var148.'</a></li>';
  8.         echo '<li><a href="http://exec-jobs.purcon.pl/pracodawca/konto/edit.php?language='.$language.'&modul_vert_menu=profile" title=Profil>'.$var149.'</a></li>';
  9.         echo "</ul>";
  10.         echo "</div>";
  11. echo "</ul>";
  12. echo "</div>";
  13.  
why #vert_menu_drop1 ul li a gets the background image of #vertmenu ul li a?
Mar 3 '08 #1
Share this Question
Share on Google+
3 Replies


oll3i
100+
P: 679
Expand|Select|Wrap|Line Numbers
  1. #vert_menu_drop1 ul li a {
  2. display: block;
  3. border:0;
  4. padding: 5px 0px 2px 4px;
  5. text-decoration: none;
  6. color: #000;
  7. width:100px;
  8. background-color:#cccccc;
  9. }
  10.  
  11.  
  12. #vertmenu {
  13. width: 100px;
  14. padding: 0px;
  15. margin: 0px;
  16. }
  17.  
  18.  
  19. #vertmenu ul li a {
  20. display: block;
  21. border:0;
  22. padding: 5px 0px 2px 4px;
  23. text-decoration: none;
  24. color: #000;
  25. width:100px;
  26. background:transparent url(http://exec-jobs.purcon.pl/images/buttonOff.gif) repeat-x top left;
  27. }
  28.  
vert_menu_drop1 ul li a inherits style of vertmenu ul li a?
Why?

i m doing unfolding menu and i want the ul li a of the submenu to be different then the main menu
Could You please help?
Thank You
Mar 4 '08 #2

oll3i
100+
P: 679
i solved it i did ul li ul li a and ul li ul li a:hover style :)
Mar 4 '08 #3

acoder
Expert Mod 15k+
P: 16,027
Moved to HTML/CSS forum.

Edit: threads merged.
Mar 4 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.