隐藏特定用户的datalist中的复选框 [英] Hide checkbox present in datalist for perticular user

查看:68
本文介绍了隐藏特定用户的datalist中的复选框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述







我使用的是datalist,其中包含复选框。现在我想隐藏普通用户的复选框,然后在那里进行特定登录,然后只有datalist显示checkBox

Hi,


I am using datalist in which checkbox are present. now I want to hide checkboxes for normal user when perticular login is there then and then only datalist shows that checkBox

推荐答案

HTML,从点击事件传递



< input type =checkboxonclick =toggle('。myClass',this this)>



在JS中传递函数



HTML, pass this from on click event

<input type="checkbox" onclick="toggle('.myClass', this)" >

In JS Pass the Function

function toggle(className, obj) {
    var


input =


(obj);
if


这篇关于隐藏特定用户的datalist中的复选框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆