l转自:https://blog.csdn.net/klo220/article/details/53331229 侵删

出现这个问题是因为input的type是file,这时如果用ng-change="()"是无效的。

解决方法:用onchange事件。

 html

<input onchange="angular.element(this).scope().add()" type="file">  

 

 js

$scope.add= function () {  

//....

}  

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-02-26
  • 2022-12-23
  • 2021-11-09
  • 2022-12-23
猜你喜欢
  • 2022-01-10
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-18
  • 2022-12-23
相关资源
相似解决方案