Тема: jQuery
Показать сообщение отдельно

  #3  
Старый 01.05.2009, 13:50
astrologer
Постоянный
Регистрация: 30.08.2007
Сообщений: 773
С нами: 9840758

Репутация: 808


По умолчанию

Код:
<!doctype html>
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <title>One by one</title>
  <script src="http://jqueryjs.googlecode.com/files/jquery-1.3.2.min.js"></script>
  <script>

  $(window).load(function()
  {
    var items = $('.landscapes li'), n = 0, l = items.length;

    /**/ items.hide(); /**/

    (function next()
    {
      if(n < l)
      {
        items.eq(n++).show('slow', next);
      }
    })();

  });


  </script>
  <style>

  html, body
  {
    margin: 0;
    background: #000;
    overflow: hidden;
  }

  .landscapes
  {
    margin: 1em;
    padding: 0;
    list-style-type: none;
  }

  .landscapes li
  {
    /** display: none; /**/
    position: relative;
    margin: 5px 0;
    width: 220px;
    height: 170px;
    border: #333 solid 1px;
  }

  .landscapes .preview
  {
    position: relative;
    top: 10px;
    left: 10px;
    display: block;
    text-decoration: none;
  }

  .landscapes .preview img
  {
    border: none;
  }

  .landscapes .preview .title
  {
    position: absolute;
    top: 5px;
    left: 5px;
    color: #000;
    font: smaller sans-serif;
  }

  </style>
</head>
<body>

<ul class="landscapes">
  <li>
    <a href="#" class="preview">
      <img src="http://www.picamatic.com/show/2009/05/01/12/00/3476906_200x150.jpg">
      <div class="title">Lorem</div>
    </a>

  <li>
    <a href="#" class="preview">
      <img src="http://www.picamatic.com/show/2009/05/01/12/00/3476910_200x150.jpg">
      <div class="title">Imsum</div>
    </a>

  <li>
    <a href="#" class="preview">
      <img src="http://www.picamatic.com/show/2009/05/01/12/00/3476908_200x150.jpg">
      <div class="title">Dolor</div>
    </a>
</ul>

</body>
</html>
 
Ответить с цитированием