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 2 of 2
  1. #1
    New to the CF scene
    Join Date
    May 2012
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    HTML+CSS div class active by default

    Hello really need help.
    How make one of .
    My code HTML:
    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8" />

    <link rel="stylesheet" href="css/taby.css" type="text/css" media="screen">
    </head>
    <body>
    <div class="tabsLink">
    <a href="#tab1">A</a>
    <a href="#tab2">B</a>
    </div>

    <br>
    <a class="tabs" id="tab1"></a>
    <div class="tab">
    <a href="http://www.google.lt">Google</a><br>
    <br>
    </div>

    <a class="tabs" id="tab2"></a>
    <div class="tab">
    <a href="http://www.nigma.ru">Nigma</FONT></a><br>
    </div>


    </body>
    </html>


    CSS code is:

    .tabs {
    opacity: 0;
    visibility: hidden;
    }
    .tab{
    position:absolute;
    visibility: hidden;
    z-index: 10;

    }
    .tabs:target+.tab {
    opacity: 1;
    visibility: visible;
    }
    .tabsLink a{
    background-color:#478CFB;
    padding:5px;
    font: bold 12pt "Trebuchet MS", tahoma, verdana, arial narrow, arial;
    color:#fff;
    text-decoration:none;

    -webkit-border-top-left-radius: 1px;
    -webkit-border-top-right-radius: 1px;
    -moz-border-radius-topleft: 1px;
    -moz-border-radius-topright: 1px;
    border-top-left-radius: 1px;
    border-top-right-radius:1px;

    }

  • #2
    Regular Coder dan-dan's Avatar
    Join Date
    Aug 2009
    Location
    England
    Posts
    483
    Thanks
    22
    Thanked 79 Times in 78 Posts
    Can you explain your problem bit better.


  •  

    Posting Permissions

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