更改复选框和文本框的可见性 [英] Change the visibility of checkbox and textbox

查看:78
本文介绍了更改复选框和文本框的可见性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨朋友

我正在使用asp.net 2003,我想将复选框和文本框的可见性更改为?true?当我点击一个单选按钮?我想用JavaScript做这个功能吗?

请帮帮我...

Hi friends
I am using the asp.net 2003 and I would like to change the visibility of a checkbox and textbox to ?true? when I click on a radio button? I want to do this function by using JavaScript?
Pls help me...

推荐答案

Heya,ammoos。


为此,你会想要使用 document.getElementById()选择每个元素,然后将每个元素的style.visibility属性设置为''visible''。
Heya, ammoos.

For that, you''ll want to use document.getElementById() to select each element and then set the style.visibility property for each one to ''visible''.


hi ...


请发布一些你做过的代码示例。你需要调用一个js-function点击单选按钮。该函数可能使用getElementById();检索对检查和文本框的引用,你必须将样式设置为''display:none''(隐藏)或''display:block''(可见)......


kind regrads
hi ...

please post some example code you have done alredy. you would need to call a js-function onclick of the radio-button. that function may use getElementById(); to retrieve a reference to the check- and textbox where you have to set the style to ''display:none'' (hidden) or ''display:block'' (visible) ...

kind regrads


heya pbmods ...


我们做了同样的事情 - 再次发布:)
heya pbmods ...

we did the sametime-posting again :)


这篇关于更改复选框和文本框的可见性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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