ng-reapte指令遍历

ng-reapte指令遍历

<!DOCTYPE html>
<html lang="en" dir="ltr">
  <head>
    <meta charset="utf-8">
    <title></title>
    <style media="screen">
      .container{
        width: 100%;
        height: 100%;
      }
      .container img{
        width: 150px;
        height: 100px;
      }
      span{
        display: block;
        width: 100%;
        height: 100px;
      }
    </style>

    <script src="https://cdn.staticfile.org/angular.js/1.4.6/angular.min.js"></script>

  </head>
  <body>
    <div data-ng-app="" data-ng-init="names=[
    {
      url:'./1.jpg'
    },
    {
      url:'./1.jpg'
    }
    ,
    {
      url:'./1.jpg'
    }
    ,
    {
      url:'./1.jpg'
    }
    ,
    {
      url:'./1.jpg'
    }]"
    >
    <span></span>
    <img data-ng-repeat="x in names" ng-src={{x.url}} alt="">
  </div>
</ul>
  </body>
</html>

 

上一篇:SQL server中获取语句执行时间


下一篇:解决Aireplay-ng信道问题