问题标签 [hide]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
3 回答
756 浏览

directory - 文件夹隐藏软件如何工作?

最近几天我一直在构建一个隐藏文件夹的应用程序(感谢此类软件的付费版本)。经过大量的谷歌搜索后,我找到了一些 shell 脚本,该脚本首先创建一个文件夹,然后将该文件夹重命名为“控制面板。{21EC2020-3AEA-1069-A2DD-08002B30309D}”。然后它会使用命令 attrib -s -h Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D} 隐藏此文件夹。这背后的基础是使其成为系统文件夹并将其隐藏。但是,如果您取消选中在文件夹中隐藏系统文件夹选项,控制面板将变为可见。我想让这个文件夹完全不可见,就像其他文件夹保护软件一样。

有人可以对此有所了解吗?

万分感谢...

0 投票
1 回答
941 浏览

asp.net - 将 BoundField 插入 DetailsView

基本上我有一个详细信息视图,取决于它是什么查询,我有某些我想显示或隐藏的 BoundFields。

使用visual basic,我知道我可以使用.visible = false。这样做可以解决问题,但是,它在此过程中牺牲了我的交替行样式。

有任何想法吗?

谢谢

顺便说一句,如果你用 C# 编写它,我可能会明白。

0 投票
5 回答
3245 浏览

javascript - Div not properly hiding in IE

I've got few divs on my website - on the load I want some of them to be hidden, some shown. I am hiding the ones I don't want like this:

It works well in Chrome, Firefox, IE8 an Opera... It doesn't in IE6 (I haven't tested on previous version yet...) - when I load the page all the divs are hidden properly. When I click a link that makes one of them visible it appears correctly. The problems shows when I click on a different link that's supposed to hide the first div and show another. The text of the first div is hidden, but the image stays and obstructs the newly shown div. I'm pretty sure it's a bug - when I zoom in or out of the page the divs that were supposed to be hidden disappear suddenly - they're only visible when I load the page.

Is there a way around it?

EDIT: I'm using jQuery v1.3.2

EDIT: Unfortunately the solution of using addClass to add css class that states display: none doesn't really work - it seemed like it did at first, but the problem is still there.

UPDATE: The js file I wrote can be found here, while the html here. The problem I have is that when you go from one portfolio to the other, the image of the first one stays there obstructing the next, even though it should be hidden (text underneath changes correctly). Wrong disappears when you try to zoom in/out of the page.
I used to hide all portfolios using $("#divId").hide(), but as was pointed out below, I now use $(".classToHide").hide().

UPDATE: The problem is solved on IE8 - I forgot to include the standards mode declaration... However, on IE6 it's still the problem.

0 投票
14 回答
211098 浏览

ios - iPhone仅在第一页隐藏导航栏

我有下面的代码隐藏和显示导航栏。它在第一个视图加载时隐藏,然后在调用“孩子”时隐藏。麻烦的是,当他们返回根视图时,我找不到触发它再次隐藏的事件/动作......

我在根页面上有一个手动执行操作的“测试”按钮,但它并不漂亮,我希望它是自动的。

0 投票
1 回答
1066 浏览

jquery - jquery中的remove事件取消了慢速隐藏事件

我有一个关于如何保持一个事件执行一个动作而不被下一行代码取消的问题在这种情况下,我不希望删除动作取消隐藏行为

也许,这属于回调类别,但我不确定在这种情况下是否可以使用它

下面的代码已经驻留在加载方法的回调中

这是代码

0 投票
4 回答
43258 浏览

javascript - 使用 Javascript 隐藏元素的下一个兄弟

我有一个从document.getElementById('the_id'). 我怎样才能得到它的下一个兄弟并隐藏它?我试过了,但没有用:

Firebug 错误是elem.nextSibling.style is undefined.

0 投票
4 回答
4605 浏览

jquery - 单击时隐藏动态创建的表行

我目前正在尝试在按下按钮后隐藏动态创建的表格行。到目前为止,我已经设法处理了部分动态功能。

每个动态行都有一个“取消”和“保存”按钮,我已经设法轻松应对这些。我的问题实际上是与行本身一起工作。

我现在需要隐藏该行,我尝试了各种方法,.parent、.attr 等等。

0 投票
3 回答
14368 浏览

javascript - 如何展示一个
如果启用了 Javascript 并且不同
如果不是?

我正在使用一些 Javascript 在<div>. 但是,如果未启用 JS,我有一个想要显示的动画 gif。我实际上使用以下代码:

外部 JS 文件在<div>. id="slideshow" 上的类设置尺寸、填充、边距、定位等。“hide-slideshow”css 文件在#slideshow 上执行“display:none”,动画 gif 周围的“adjust”类执行一些操作推拉把它放到它需要的地方(如果它没有被隐藏,那就是幻灯片的地方)。

我已经在 FF3、IE7、IE8、Chrome 和 Safari (Win) 中对此进行了测试。好消息是它就像一个魅力。坏消息是它没有通过 W3C 验证器。我收到一条错误消息,提示“文档类型不允许此处的元素“链接””。

即使我的方法有效,是不是太笨拙了?<div>如果启用了 JS,是否有更好的方法来显示一个,如果<div>没有,是否有一种不同的方法,以一种跨浏览器工作并通过验证的方式?

谢谢!

0 投票
2 回答
1841 浏览

jquery - How can I use Jquery's Coolinput to show the hint "Enter your password" in a password field, but then use stars to hide the input when user types?

pretty self explanatory...

0 投票
3 回答
2152 浏览

cocoa - Cocoa:隐藏一个应用程序

是否可以使用可可隐藏一个特定的应用程序?

我知道您可以使用以下代码隐藏所有其他应用程序

但是是否可以只隐藏一个特定的应用程序,例如 Safari?