problem with dividers

problem with dividers

in the next file when i run it . the list it create for me have two name 'house' and 'tree'. the problem that the list is not autodividers , only when i search for name in the list it make the list with dividers

  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4.     <title>First jQuery Mobile Example</title>
  5.     <!-- the three things that jQuery Mobile needs to work -->
  6.     <link rel="stylesheet" href="jquery.mobile-1.4.2/jquery.mobile-1.4.2.css" />
  7.     <script src="jquery-1.11.0.js" type="text/javascript"></script>
  8.     <script src="jquery.mobile-1.4.2/jquery.mobile-1.4.2.js" type="text/javascript"></script>
  9.     <meta name="viewport" content="width=device-width"/>
  10. </head>
  11. <body>


  12. <!-- This is the first page -->
  13. <section id="firstpage" data-role="page">
  14.     <div data-role="header">
  15.         <h1>Page Content Header</h1>
  16.     </div>

  17.     <ol data-role="listview" data-autodividers="true" data-filter="true" data-inset="true" id="listOfItemes">
  18.     </ol>

  19.     <div class="ui-content" role="main">
  20.         <p>This is the content on page 1</p>
  21.         <p><a href="#secondpage">Go to second page</a></p>
  22.     </div>
  23.     <div data-role="footer">
  24.         <h2>Page Content Footer</h2>
  25.     </div>
  26. </section>

  27. <!-- This is the second page -->
  28. <div id="secondpage" data-role="page">
  29.     <div data-role="header">
  30.         <h1>Page Content Header</h1>
  31.     </div>
  32.     <div class="ui-content" role="main">
  33.         <p>Page 2 has different content on it</p>
  34.         <p><a href="#firstpage">Go to first page</a></p>
  35.     </div>
  36.     <div data-role="footer">
  37.         <h2>Page Content Footer</h2>
  38.     </div>
  39. </div>

  40. <script>
  41.     var output = '';

  42.     $.ajax({
  43.         url: 'https://c9.io/a1_shay/blabla/workspace/myFirstJson.json',
  44.         dataType: 'json',
  45.         type: 'get',
  46.         cache: false,
  47.         success: function(data)
  48.         {
  49.             $(data.articles).each(function(index, value)
  50.                     {
  51.                         output += '<li>' + value.name + '</li>';
  52.                     }

  53.             )
  54.             console.log(output);
  55.             var update = document.getElementById('listOfItemes');
  56.             update.innerHTML = output;
  57.         }
  58.     })
  59. </script>

  60. </body>
  61. </html>