小编Cod*_*ant的帖子

Jquery change event not working

I have html:

<form id="fileuploadform">
    <input type="file" id="fileupload" name="fileupload" />
</form>
Run Code Online (Sandbox Code Playgroud)

and jquery:

$(':file').change(function(){
    var file = this.files[0];
    ...
});
Run Code Online (Sandbox Code Playgroud)

The problem is: the change function fires only when the file selection is different than the selection made previously. That is of course the meaning of the 'change' event. I want my function to be called with the file dialog closes, no matter what.

我尝试使用 'select' 事件——它永远不会被调用

我也试过:

$(':file').bind('dialogclose', function(event) {
    alert('closed');
});
Run Code Online (Sandbox Code Playgroud)

和:

$(':file').live("dialogclose", function(){
    alert('closed1');
}); 
Run Code Online (Sandbox Code Playgroud)

他们也没有工作。

html javascript jquery

5
推荐指数
3
解决办法
2万
查看次数

CakePHP Acl自动检查

我是CakePHP框架的新手.我对CakePHP知之甚少.所以我的问题是:ACL是自动运行还是我需要手动检查?

php acl cakephp cakephp-2.0 cakephp-2.1

4
推荐指数
1
解决办法
989
查看次数

需要解释一下术语[0] ==![0]

这个词[0] == ![0]意味着什么?虽然他们返回true.但我需要解释它true是如何返回的,因为[0]的类型是对象而且![0]返回布尔值?那他们是如何平等的呢?谢谢

javascript

1
推荐指数
2
解决办法
192
查看次数

标签 统计

javascript ×2

acl ×1

cakephp ×1

cakephp-2.0 ×1

cakephp-2.1 ×1

html ×1

jquery ×1

php ×1