javascript - The input element's type ('hidden') does not support selection
PHP中文网
PHP中文网 2017-04-11 12:24:50
[JavaScript讨论组]

Uncaught DOMException: Failed to read the 'selectionStart' property from 'HTMLInputElement': The input element's type ('hidden') does not support selection.

不懂这是为什么导致的~有过来人帮忙解毒下吗?代码如下

    function eventUp(e){    
            layer(ctx);
        e.preventDefault();
        mousedown=false;
            setTimeout(function(){
            $.alert(awardsmsg, "msg", function() {
                $.ajax({
                    method: "POST",
                    url: "max.php",
                    data: {
                        unionid: unionid,
                        openid: openid,
                        nickname: nickname,
                        exchange: awardsexchange
                    },
                    success: function(){
                        wx.closeWindow();                                            
                    }
            });
            });    
            },456);
    }
PHP中文网
PHP中文网

认证高级PHP讲师

全部回复(2)
PHPz

这个问题后来发现是我的值没传递下来。。。只要值传递下来了给值正确就不会有这个问题了

PHP中文网

感觉应该是对元素做取值操作的时候有问题
参考下这个问题
和这个问题

热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责申明 举报中心 意见反馈 讲师合作 广告合作 最新更新
php中文网:公益在线php培训,帮助PHP学习者快速成长!
关注服务号 技术交流群
PHP中文网订阅号
每天精选资源文章推送

Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号