div标签在运行时隐藏 [英] div tag hide at run time
本文介绍了div标签在运行时隐藏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
您好,
i只想了解如何在运行时获取隐藏div标签。
例如:
Hello,
i just wanna know about how to get hide div tag at run time.
for ex:
< asp:textbox id =txt1run =server>
<asp:textbox id="txt1" run="server">
i没有提供runat = div标签中的server..因为我使用了脚本..如果在div标签中使用runat =server,则脚本无效
请告诉我一个解决方案
i didn't provide runat="server" in div tag.. because i had using a script.. the script is not working if am using runat= "server" in that div tag
plz tell me one solution
推荐答案
然后注册一个脚本并将设置为div的可见性隐藏。试试这样:
Then register a script and set visibility of div to hidden. Try like this:
Page.ClientScript.RegisterStartupScript(this.GetType(), "clientscript", "document.getElementById('YourDivID').style.visibility = 'hidden';" ,true);
>
我认为你可以使用jQuery隐藏div。
Hi,
I think you can use jQuery to hide the div.
(# divID)。hide();
谢谢
("#divID").hide();
Thank You
这篇关于div标签在运行时隐藏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文