HTML控件设置 visible="false" 但还是显示了_html/css_WEB-ITnose
Jun 21, 2016 am 09:44 AMHTML 控件 visible
我有一个按钮在运行时查看代码是这样的,但为什么还是显示出来了呢?
回复讨论(解决方案)
控制显不显示,是在样式里设置 obj.style.display="none"
style
display:none
或
visibility:hidden 这个会依然保留元素所在位置
visible="false"应该是.net 加了runat=server之后起作用的

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

Difficulty in updating caching of official account web pages: How to avoid the old cache affecting the user experience after version update?

How do I use HTML5 form validation attributes to validate user input?

How to efficiently add stroke effects to PNG images on web pages?

What is the purpose of the <iframe> tag? What are the security considerations when using it?

What are the security implications of using iframes, and how can I mitigate them?

What are the best practices for cross-browser compatibility in HTML5?

How do I use the HTML5 <time> element to represent dates and times semantically?

How do I use the HTML5 <meter> element to display numerical data within a range?
