Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    May 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    li with class trouble

    Im working in a system that creates this code when i create a menu:
    Code:
    <div id="menu">
    <div id="menucontainer">
    <ul>
    <li>Topcategory
    <ul>
    <li class="submeny1">Subcategory
    <li class="submeny2">Subsubcategory</li>
    <li class="submeny2">Subsubcategory</li>
    <li class="submeny2">Subsubcategory</li>
    </li>
    <li class="submeny1">Subcategory</li>
    <li class="submeny1">Subcategory</li>
    <li class="submeny1">Subcategory</li>
    </ul>
    </li>
    <li>Topcategory</li>
    <li>Topcategory</li>
    <li>Topcategory</li>
    </ul>
    </div>
    </div>
    Can someone help me figure out how to control the subcategory and the subsubcategory with css? Ive tried everything but I cant seem to control the classes?

  • #2
    Regular Coder ajhauser's Avatar
    Join Date
    Nov 2007
    Location
    Earlville. It's where Earls come from.
    Posts
    226
    Thanks
    74
    Thanked 1 Time in 1 Post
    As far as CSS goes - you already have your classes for the seperate catagories. You can style each of those with CSS - is that what you are asking?

    What CSS do you have already (if any)?

  • #3
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,865
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    If you are trying to make a drop down menu, http://htmldog.com/articles/suckerfish/dropdowns/ is a good resource to follow.
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #4
    New to the CF scene
    Join Date
    May 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    The thing is that i cant change the html code, its created by a cms. But ive tried to control it with css like this:

    Code:
    		
    #menu { 
            color: #000000;
       		margin:0px;
            background-color:#ffffff;
    		margin-left: 40px;
    		width: 560px;} 
    
    #menucontainer {
    		margin: 0;
    		padding: 0px;
    		font: 11px arial black, georgia, trebuchet ms;}
    
    		#menucontainer ul{
    		margin:0px;
    		padding: 0;
    		list-style-type: none;}
    		
    		#menucontainer li{ 
    		margin: 0; }
    
    		#menucontainer a{
    		display: block;
    		color: #121D31;
            background:url(menucontainerbg.png) transparent no-repeat;
            width: 160px;
            height: 19px;
    	    margin-bottom: 12px;
    		padding:2px 0px 0px 24px;
    		text-decoration: none;
    		border-bottom: 0px dotted #ccc;}
    		
    		#menucontainer li a.active{
    		background: url(active.png) transparent no-repeat;
            text-decoration: none;			
            color: #000;
    		border-bottom: 0px dotted #bbb;
            font-weight: bold;}
    		
    		
    		.submeny1 a{
    			display: block;
    			color: #9BA9B9;
    			background: url(subbg.png) transparent no-repeat;
    			padding:0px;
    			margin: 0px;
    			padding-left: 30px;     
    			text-decoration: none;
    			border: 0px solid #ffffff;}
    		
    	    .submeny1 a.active{
    			background: url(subactive.png) transparent no-repeat;
                text-decoration: none;			
                color: #ffffff;}
    		
    		
    		.submeny2 a{
    			display: block;
    			color: #9BA9B9;
    			background: url(subsubbg.png) transparent no-repeat;
    			padding:0px;
    			margin: 0px;
    			font: 10px arial, georgia, trebuchet ms;
    			padding-left: 30px;     
    			text-decoration: none;
    			border: 0px solid #ffffff;}
    			
    		.submeny2 a.active{
    			background: url(subactive.png) transparent no-repeat;
                text-decoration: none;			
                color: #ffffff;}

  • #5
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,865
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    Can someone help me figure out how to control the subcategory and the subsubcategory with css? Ive tried everything but I cant seem to control the classes?
    The thing is that i cant change the html code, its created by a cms. But ive tried to control it with css like this:
    Control? Your intention is still not clear!
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #6
    New to the CF scene
    Join Date
    May 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by abduraooft View Post
    Control? Your intention is still not clear!
    I want to control the style of the subcategory and the subsubcategory, change color, size etc. But i cant find the right css code to do this, ive tried different code for the classes but it doesnt affect the style of the meny.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •