【代码笔记】Web-ionic单选框

一,效果图。

 

 

二,代码。

 

复制代码
<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>Todo</title>
    <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
    <link href="lib/ionic/css/ionic.css" rel="stylesheet">
    <script src="lib/ionic/js/ionic.bundle.js"></script>
    <!-- 在使用 Cordova/PhoneGap 创建的 APP 中包含的文件,由 Cordova/PhoneGap 提供,(开发过程中显示 404) -->
    <script src="js/app2.js"></script>
    <script src="cordova.js"></script>
    <link href="http://www.runoob.com/static/ionic/css/ionic.min.css" rel="stylesheet">
    <script src="http://www.runoob.com/static/ionic/js/ionic.bundle.min.js"></script>
</head>

<body>
    <div class="list">
        <label class="item item-radio">
            <input type="radio" name="group" value="go" checked="checked">
            <div class="item-content">
                Go
            </div>
            <i class="radio-icon ion-checkmark"></i>
        </label>
        <label class="item item-radio">
            <input type="radio" name="group" value="python">
            <div class="item-content">
                Python
            </div>
            <i class="radio-icon ion-checkmark"></i>
        </label>
        <label class="item item-radio">
            <input type="radio" name="group" value="ruby">
            <div class="item-content">
                Ruby
            </div>
            <i class="radio-icon ion-checkmark"></i>
        </label>
        <label class="item item-radio">
            <input type="radio" name="group" value=".net">
            <div class="item-content">
                .Net
            </div>
            <i class="radio-icon ion-checkmark"></i>
        </label>
        <label class="item item-radio">
            <input type="radio" name="group" value="java">
            <div class="item-content">
                Java
            </div>
            <i class="radio-icon ion-checkmark"></i>
        </label>
        <label class="item item-radio">
            <input type="radio" name="group" value="php">
            <div class="item-content">
                PHP
            </div>
            <i class="radio-icon ion-checkmark"></i>
        </label>
    </div>
</body>

</html>
复制代码

 

参考资料:《菜鸟教程》

posted @ 2018-07-25 09:10  花儿迎风笑  阅读(363)  评论(0编辑  收藏  举报