RELATEED CONSULTING
相关咨询
选择下列产品马上在线沟通
服务时间:8:30-17:00
你可能遇到了下面的问题
关闭右侧工具栏

新闻中心

这里有您想知道的互联网营销解决方案
js小键盘需求
/* container */
    #container {
        margin: 100px auto;
        width: 488px;
    }

    #keyboard {
        margin: 0;
        padding: 0;
        list-style: none;
    }

    #keyboard li {
        float: left;
        margin: 0 5px 5px 0;
        width: 40px;
        height: 40px;
        line-height: 40px;
        text-align: center;
        background: #fff;
        border: 1px solid #f9f9f9;
        cursor: pointer;
        -moz-border-radius: 5px;
        -webkit-border-radius: 5px;
        font-size: 20px;
    }
    
        #keyboard li:hover {
            position: relative;
            top: 1px;
            left: 1px;
            border-color: #e5e5e5;
            background: #FFF1C2;
        }
    
    #keyboard .delete {
        width: 180px;
        font-size: 20px;

js代码

成都创新互联公司专注于网站建设|网页维护|优化|托管以及网络推广,积累了大量的网站设计与制作经验,为许多企业提供了网站定制设计服务,案例作品覆盖垃圾桶等行业。能根据企业所处的行业与销售的产品,结合品牌形象的塑造,量身策划品质网站。

 $(function () {
        $("#Batchid").bind('focus', function () {           
            //键盘显示
            $("#container").show();
        });
        //点击
        $(".letter").bind('click', function () {
            $("#Batchid").val($("#Batchid").val() + "" + $(this).html());
        });
        //删除
        $("#delete").bind('click', function () {
            var html = $("#Batchid").val()

            $("#Batchid").val(html.substr(0, html.length - 1));
        });
        
    });

页面代码

 
            
                
                    
                        
                            

商品码:

                                                                                                                                                                                                       

批    号:

                                                                                                                                                          
                                          
        
                                      1                 2                 3                 4                 5                 6                 7                 8                 9                 0                                 q                 w                 e                 r                 t                 y                 u                 i                 o                 p                 a                 s                 d                 f                 g                 h                 j                 k                 l                                 z                 x                 c                                 v                 b                 n                 m                 删除                      

最后效果 搞了两个多小时 

js 小键盘需求


名称栏目:js小键盘需求
文章路径:http://scyingshan.cn/article/pohcoh.html