css problem with the scroll bar

Discussion in 'CSS' started by crazy.works, Nov 3, 2008.

  1. #1
    hello guys,
    i have problem in the scroll bar on my css code , i am trying to use that css menu from that link http://www.cssplay.co.uk/menus/slide_fly.html

    it actually works very good but i want to use it on the right side from my site not in the left side so i edited the ccs code but the scroll bar didnt works really good ,it scroll so much on the left side ,
    here is screen shot http://qbael.com/upload/mn/screen.JPG

    and here is my css code after the editing.

    
    
    #menu {list-style-type:none; padding:0; margin:0; width:150px; z-index:100; float:right; height:360px; background:#000;}
    #menu ul {list-style-type:none; padding:0; margin:0;}
    #menu li {float:left; background:#fff url(slide/slide_0.gif) no-repeat;}
    
    #menu li.sub {background:#fff url(slide/slide_0.gif) no-repeat;}
    
    #menu li, #menu li a {display:block; color:#fff; font-family:arial, sans-serif; font-size:11px; line-height:30px; width:150px; text-decoration:none; cursor:pointer; font-weight:bold; text-align:center;}
    
    #menu table {border-collapse:collapse; padding:0; margin:0 -1px -1px;}
    
    #menu ul,
    #menu :hover ul ul,
    #menu :hover ul :hover ul ul {position:absolute; right:-9999px; width:150px;}
    
    #menu :hover {color:#ff0; background:#fff url(slide/slide_1.gif) no-repeat; z-index:500; white-space:nowrap;}
    
    #menu :hover > a {color:#ff0; background:#fff url(slide/slide_1.gif) no-repeat; z-index:500; white-space:nowrap;}
    
    #menu :hover ul {position:static; height:180px; margin-top:-1px; background:#383838;}
    #menu :hover ul :hover ul, 
    #menu :hover ul :hover ul :hover ul {display:block; position:absolute; right:130px; top:0; height:auto; z-index:500; border:1px solid #fff;}
    
    #menu :hover ul li, #menu :hover ul li a {background:#383838; text-align:right; text-indent:10px; }
    #menu :hover ul li.fly a {background: #383838 url(slide/arrow.gif) no-repeat 20px center;}
    #menu :hover ul :hover {background:#255fa3; position:relative; z-index:100;}
    #menu a:hover ul li.fly a:hover {background:#255fa3 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    #menu :hover ul li.fly:hover > a {background:#255fa3 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    
    #menu :hover ul :hover ul li, 
    #menu :hover ul :hover ul li a
    {background:#666;}
    #menu :hover ul :hover ul :hover ul li {background:#666; z-index:500;}
    
    #menu :hover ul :hover ul li.fly a {background: #626262 url(slide/arrow.gif) no-repeat 20px center;}
    #menu :hover ul :hover ul :hover {z-index:500; background:#0d72c0; color:#ff0;}
    #menu a:hover ul a:hover ul li.fly a:hover {background:#0d72c0 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    #menu :hover ul :hover ul li.fly:hover > a {background:#0d72c0 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    
    #menu :hover ul :hover ul :hover ul li, 
    #menu :hover ul :hover ul :hover ul li a {background:#888;}
    
    #menu :hover ul :hover ul :hover ul :hover {background:#5184b8; color:#ff0;}
    #menu :hover ul :hover ul :hover ul :hover a {color:#ff0;}
    
    .text {float:right; width:500px; font: 11px verdana, arial, sans-serif; border:1px solid #000; height:358px;}
    .text img  {display:block;}
    .text p {margin:0; padding:5px 10px; line-height:15px;}
    
    
    Code (markup):
    so please help me to fix it .

    thanks
     
    crazy.works, Nov 3, 2008 IP
  2. crazy.works

    crazy.works Peon

    Messages:
    304
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    and that was the code before my edit

    
    
    
    #menu {list-style-type:none; padding:0; margin:0; width:150px; z-index:100; float:left; height:360px; background:#000;}
    #menu ul {list-style-type:none; padding:0; margin:0;}
    #menu li {float:left; background:#fff url(slide/slide_0.gif) no-repeat;}
    
    #menu li.sub {background:#fff url(slide/slide_0.gif) no-repeat;}
    
    #menu li, #menu li a {display:block; color:#fff; font-family:arial, sans-serif; font-size:11px; line-height:30px; width:150px; text-decoration:none; cursor:pointer; font-weight:bold; text-align:center;}
    
    #menu table {border-collapse:collapse; padding:0; margin:0 -1px -1px;}
    
    #menu ul,
    #menu :hover ul ul,
    #menu :hover ul :hover ul ul {position:absolute; left:-9999px; width:150px;}
    
    #menu :hover {color:#ff0; background:#fff url(slide/slide_1.gif) no-repeat; z-index:500; white-space:nowrap;}
    
    #menu :hover > a {color:#ff0; background:#fff url(slide/slide_1.gif) no-repeat; z-index:500; white-space:nowrap;}
    
    #menu :hover ul {position:static; height:180px; margin-top:-1px; background:#383838;}
    #menu :hover ul :hover ul, 
    #menu :hover ul :hover ul :hover ul {display:block; position:absolute; left:130px; top:0; height:auto; z-index:500; border:1px solid #fff;}
    
    #menu :hover ul li, #menu :hover ul li a {background:#383838; text-align:left; text-indent:10px; }
    #menu :hover ul li.fly a {background: #383838 url(slide/arrow.gif) no-repeat 120px center;}
    #menu :hover ul :hover {background:#255fa3; position:relative; z-index:100;}
    #menu a:hover ul li.fly a:hover {background:#255fa3 url(slide/arrow.gif) no-repeat 120px center; color:#ff0;}
    #menu :hover ul li.fly:hover > a {background:#255fa3 url(slide/arrow.gif) no-repeat 120px center; color:#ff0;}
    
    #menu :hover ul :hover ul li, 
    #menu :hover ul :hover ul li a
    {background:#666;}
    #menu :hover ul :hover ul :hover ul li {background:#666; z-index:500;}
    
    #menu :hover ul :hover ul li.fly a {background: #626262 url(slide/arrow.gif) no-repeat 120px center;}
    #menu :hover ul :hover ul :hover {z-index:500; background:#0d72c0; color:#ff0;}
    #menu a:hover ul a:hover ul li.fly a:hover {background:#0d72c0 url(slide/arrow.gif) no-repeat 120px center; color:#ff0;}
    #menu :hover ul :hover ul li.fly:hover > a {background:#0d72c0 url(slide/arrow.gif) no-repeat 120px center; color:#ff0;}
    
    #menu :hover ul :hover ul :hover ul li, 
    #menu :hover ul :hover ul :hover ul li a {background:#888;}
    
    #menu :hover ul :hover ul :hover ul :hover {background:#5184b8; color:#ff0;}
    #menu :hover ul :hover ul :hover ul :hover a {color:#ff0;}
    
    .text {float:left; width:500px; font: 11px verdana, arial, sans-serif; border:1px solid #000; height:358px;}
    .text img  {display:block;}
    .text p {margin:0; padding:5px 10px; line-height:15px;}
    
    
    
    Code (markup):
     
    crazy.works, Nov 3, 2008 IP
  3. snake charmer

    snake charmer Guest

    Messages:
    78
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    you have a lot of id's why dont you break it down a bit with some classes where you want styles. I use div id's # for areas backgrounds etc and classes . for styles of text etc...
     
    snake charmer, Nov 4, 2008 IP
  4. crazy.works

    crazy.works Peon

    Messages:
    304
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    okay here is the full code including the html , the css and please help me to fix

    
    
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" dir="rtl" xml:lang="en">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title> Stu Nicholls | CSSplay | Vertical slide </title>
    <meta name="Author" content="Stu Nicholls" />
    <style type="text/css">
    
    
    #menu {list-style-type:none; padding:0; margin:0; width:150px; z-index:100; float:right; height:360px; background:#000;}
    #menu ul {list-style-type:none; padding:0; margin:0;}
    #menu li {float:left; background:#fff url(slide/slide_0.gif) no-repeat;}
    
    #menu li.sub {background:#fff url(slide/slide_0.gif) no-repeat;}
    
    #menu li, #menu li a {display:block; color:#fff; font-family:arial, sans-serif; font-size:11px; line-height:30px; width:150px; text-decoration:none; cursor:pointer; font-weight:bold; text-align:center;}
    
    #menu table {border-collapse:collapse; padding:0; margin:0 -1px -1px;}
    
    #menu ul,
    #menu :hover ul ul,
    #menu :hover ul :hover ul ul {position:absolute; right:-9999px; width:150px;}
    
    #menu :hover {color:#ff0; background:#fff url(slide/slide_1.gif) no-repeat; z-index:500; white-space:nowrap;}
    
    #menu :hover > a {color:#ff0; background:#fff url(slide/slide_1.gif) no-repeat; z-index:500; white-space:nowrap;}
    
    #menu :hover ul {position:static; height:180px; margin-top:-1px; background:#383838;}
    #menu :hover ul :hover ul, 
    #menu :hover ul :hover ul :hover ul {display:block; position:absolute; right:130px; top:0; height:auto; z-index:500; border:1px solid #fff;}
    
    #menu :hover ul li, #menu :hover ul li a {background:#383838; text-align:right; text-indent:10px; }
    #menu :hover ul li.fly a {background: #383838 url(slide/arrow.gif) no-repeat 20px center;}
    #menu :hover ul :hover {background:#255fa3; position:relative; z-index:100;}
    #menu a:hover ul li.fly a:hover {background:#255fa3 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    #menu :hover ul li.fly:hover > a {background:#255fa3 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    
    #menu :hover ul :hover ul li, 
    #menu :hover ul :hover ul li a
    {background:#666;}
    #menu :hover ul :hover ul :hover ul li {background:#666; z-index:500;}
    
    #menu :hover ul :hover ul li.fly a {background: #626262 url(slide/arrow.gif) no-repeat 20px center;}
    #menu :hover ul :hover ul :hover {z-index:500; background:#0d72c0; color:#ff0;}
    #menu a:hover ul a:hover ul li.fly a:hover {background:#0d72c0 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    #menu :hover ul :hover ul li.fly:hover > a {background:#0d72c0 url(slide/arrow.gif) no-repeat 20px center; color:#ff0;}
    
    #menu :hover ul :hover ul :hover ul li, 
    #menu :hover ul :hover ul :hover ul li a {background:#888;}
    
    #menu :hover ul :hover ul :hover ul :hover {background:#5184b8; color:#ff0;}
    #menu :hover ul :hover ul :hover ul :hover a {color:#ff0;}
    
    </style>
    </head>
    
    <body>
    <ul id="menu">
    <li><a href="#nogo">Home</a></li>
    <li><a href="#nogo">Privacy Policy</a></li>
    <li class="sub"><a href="#nogo">Types<!--[if gte IE 7]><!--></a><!--<![endif]-->
                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                            <li><a href="#nogo">European</a></li>
                            <li><a href="#nogo">Indian</a></li>
                            <li><a href="#nogo">North Africa</a></li>
                            <li class="fly"><a href="#nogo">American<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">South American</a></li>
                                            <li class="fly"><a href="#nogo">North American<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                                            <li><a href="#nogo">Grey tree frog</a></li>
                                                            <li><a href="#nogo">Green tree frog</a></li>
                                                            <li><a href="#nogo">Spring peeper</a></li>
                                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                                            </li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                            <li><a href="#nogo">Japanese</a></li>
                            <li><a href="#nogo">Chinese</a></li>
                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
    </li>
    <li class="sub"><a href="#nogo">Classifications<!--[if gte IE 7]><!--></a><!--<![endif]-->
                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                            <li class="fly"><a href="#nogo">Pelodryadinae<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">Cyclorana</a></li>
                                            <li><a href="#nogo">Litoria</a></li>
                                            <li><a href="#nogo">Nyctimystes</a></li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                            <li class="fly"><a href="#nogo7">Phyllomedusinae<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">Agalychnis</a></li>
                                            <li><a href="#nogo">Cruziohyla</a></li>
                                            <li><a href="#nogo">Hylomantis</a></li>
                                            <li><a href="#nogo">Pachymedusa</a></li>
                                            <li><a href="#nogo">Phasmahyla</a></li>
                                            <li><a href="#nogo">Phrynomedusa</a></li>
                                            <li><a href="#nogo">Phyllomedusa</a></li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                            <li class="fly"><a href="#nogo">Hemiphractinae<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">Cryptobatrachus</a></li>
                                            <li><a href="#nogo">Flectonotus</a></li>
                                            <li><a href="#nogo">Gastrotheca</a></li>
                                            <li><a href="#nogo">Hemiphractus</a></li>
                                            <li><a href="#nogo">Stefania</a></li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                            <li class="fly"><a href="#nogo">Hylinae<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">Acris</a></li>
                                            <li><a href="#nogo">Anotheca</a></li>
                                            <li><a href="#nogo">Bokermannohyla</a></li>
                                            <li><a href="#nogo">Corythomantis</a></li>
                                            <li><a href="#nogo">Ecnomiohyla</a></li>
                                            <li><a href="#nogo">Hyloscirtus</a></li>
                                            <li><a href="#nogo">Megastomatohyla</a></li>
                                            <li><a href="#nogo">Osteocephalus</a></li>
                                            <li><a href="#nogo">Pseudacris</a></li>
                                            <li><a href="#nogo">Sphaenorhynchus</a></li>
                                            <li><a href="#nogo">Trachycephalus</a></li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                            <li class="fly"><a href="#nogo9">Rhacophorinae<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">Boophis</a></li>
                                            <li><a href="#nogo">Callixalus</a></li>
                                            <li><a href="#nogo">Chiromantis</a></li>
                                            <li><a href="#nogo">Cryptothylax</a></li>
                                            <li><a href="#nogo">Mantidactylus</a></li>
                                            <li><a href="#nogo">Rhacophorus</a></li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                            <li class="fly"><a href="#nogo">Buergeriinae<!--[if gte IE 7]><!--></a><!--<![endif]-->
                                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                                            <li><a href="#nogo">Buergeria</a></li>
                                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
                            </li>
                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
    </li>
    <li class="sub"><a href="#nogo">References<!--[if gte IE 7]><!--></a><!--<![endif]-->
                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                            <li><a href="http://en.wikipedia.org/wiki/Tree_frog">Wikipedia</a></li>
                            <li><a href="#nogo11">Encyclopedia</a></li>
                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
    </li>
    <li class="sub"><a href="#nogo">Links<!--[if gte IE 7]><!--></a><!--<![endif]-->
                    <!--[if lte IE 6]><table><tr><td><![endif]--><ul>
                            <li><a href="#nogo">Complete treefrog</a></li>
                            <li><a href="#nogo">Old World treefrogs</a></li>
                            <li><a href="#nogo">Amphibian Species</a></li>
                    </ul><!--[if lte IE 6]></td></tr></table></a><![endif]-->
    </li>
    </ul>
    
    </body>
    </html>
    
    
    
    
    Code (markup):
     
    crazy.works, Nov 4, 2008 IP
  5. crazy.works

    crazy.works Peon

    Messages:
    304
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    please help any suggestion ???:(
     
    crazy.works, Nov 4, 2008 IP