如何禁用和启用输入类型? [英] how can I disable and enable input type?

查看:54
本文介绍了如何禁用和启用输入类型?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



紧急

如果rs(" field")= =

,如何启用和删除输入字段? 1然后

desable

elseif re(" field")= 2 then

enable

end if if

和chek之后如果输入类型是启用那么manadatory字段不能为$

谢谢

解决方案

使用JavaScript,您将使用disabled属性。但是,如果您要在页面加载ASP时设置它,只需将其包含在标记内:

展开 | < span class =codeLinkonclick =selectAll(this);>选择 | Wrap | 行号


嗨..

u可直接在页面中使用

喜欢

[HTML]< input type =''control- text /按钮等''name =''''id =''''<%如果rs(" field")= 1则%>

disabled = true<%elseif re( " field")= 2 then%> disabled = false<%end if if>> [/ HTML]


hi

我想要在...中使用它sp与vbscripts

我需要的是如果选择的选项是floopy和cd然后目的输入字段是启用(显示)ohterwiese目的输入字段是(隐藏)

谢谢

Hi
its urgent
how can enable and desable the input field with condition like
if rs("field")=1 then
desable
elseif re("field")=2 then
enable
end if
and that after chek if the input type is enable then manadatory field can''t null
thanks

解决方案

With JavaScript, you''d use the disabled property. However, if you''re going to set it whilst the page is loading with ASP, just include it within the tag:

Expand|Select|Wrap|Line Numbers


Hi..
u can used directly in page
like
[HTML]<input type=''control- text/button etc'' name='''' id='''' <%if rs("field")=1 then%>
disabled=true <%elseif re("field")=2 then%>disabled=false<%end if%>>[/HTML]


hi
I wants to use it in asp with vbscripts
and my need is to if selected option is floopy and cd then purpose Input filed is enable(show) ohterwiese purpose input field is(hide)
Thanks


这篇关于如何禁用和启用输入类型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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