如何在水平表格单元格中放置按钮?

时间:2014-09-11 15:38:29

标签: html css

如何将按钮水平放置在表格单元格中?

在设计单选按钮后,它们移出并开始垂直放置

<tr>
    <td>
        <label>Выпускник <a href="http:\\www.htmlacademy.ru">htmlacademy.ru</a>
            <input type="radio" name="haru" id="c1" value="yes" checked/>
            <label for="c1"><span></span>Да</label>
            <input type="radio" name="haru" id="c2" value="no">
            <label for="c2"><span></span>Нет</label>
        </label>
    </td>
</tr>
input[type="radio"] {
    display:none;
}

input[type="radio"] + label span {
    display:inline-block;
    width:41px;
    height:45px;
    background:url(rad0.png);
    cursor:pointer;
}

input[type="radio"]:checked + label span {
    display:inline-block;
    width:41px;
    height:45px;
    background:url(rad1.png);
    cursor:pointer;
}

0 个答案:

没有答案