[html/css] radio

Discussion in 'Болталка' started by zlo12, 10 Jul 2012.

  1. zlo12

    zlo12 Elder - Старейшина

    Joined:
    28 Dec 2007
    Messages:
    535
    Likes Received:
    135
    Reputations:
    34
    ---
    В общем есть такая конструкция
    PHP:
    <style type="text/css">.tabs positionabsolutemin-height900pxclearbothmargin25px 0; } .tab floatleft; } .tab label background#eee; padding: 10px; border: 1px solid #ccc; margin-left: -1px; position: relative; left: 1px; } .tab [type=radio] { display: none;}.content { position: absolute; min-width:675px; top: 62px; left: 0; background: white; right: 0; bottom: 0; padding: 20px; border: 1px solid #ccc;}[type=radio]:checked ~ label { background: white; border-bottom: 1px solid white; z-index: 2;}[type=radio]:checked ~ label ~ .content { z-index: 1;} .tabs2 { position: absolute; min-height: 900px; clear: both; margin: 61px 0; }.tab { float: left; }.tab label { background: #eee; padding: 10px; border: 1px solid #ccc; margin-left: -1px; position: relative; left: 1px; } .tab [type=radio] { display: none;}.content2 { position: absolute; top: 26px;min-width:675px; left: 0; background: white; right: 0; bottom: 0; padding: 20px; border: 1px solid #ccc;}[type=radio]:checked ~ label { background: white; border-bottom: 1px solid white; z-index: 2;}[type=radio]:checked ~ label ~ .content { z-index: 1;}</style>
    <div>
    <
    div class="tabs">
      <
    div class="tab">
        <
    input type="radio" id="tab-1" name="tab-group-1" checked="checked"="checked="checked"" ="checked="checked"="checked="checked"" "="checked="checked"=" checked="checked""="checked="checked"=" checked="checked"""="" checked="checked""""="" """="" =""="" />
        <label for="
    tab-1">label1</label>
        <div class="
    content">
         blabla
            </div></div>
      <div class="
    tab">
        <input type="
    radio" id="tab-2" name="tab-group-1" />
        <label for="
    tab-2">label2</label>
        blabla    
            </div></div></div>
      
        <div class="
    tabs2">
          <div class="
    tab">
                         <input type="
    radio" id="tab-9" name="tab-group-1" />
        <label for="
    tab-9">label9</label>
        <div class="
    content2">
    blabla
         </div></div>
                    <div class="
    tab">
                          <input type="
    radio" id="tab-10" name="tab-group-1" />
        <label for="
    tab-10">label10</label>
        <div class="
    content2">
    blabla
         </div></div></div>
      
    Получается 2 ряда кнопочек. Верхний ряд ведёт себя адекватно и без проблем. Но вот нижний отображает только сожернимое последней кнопки, хотя нажимаются все.
    За сутки не смог понять почему. Подскажите где ошибка?
     
    #1 zlo12, 10 Jul 2012
    Last edited: 10 Jul 2012
  2. zlo12

    zlo12 Elder - Старейшина

    Joined:
    28 Dec 2007
    Messages:
    535
    Likes Received:
    135
    Reputations:
    34
    таки ап