Create list items in javascript
<p>I am working on cordova app .I want to create list items using jquery . here is my html code :</p>

<pre><code> &lt;div class="body" id="list"&gt;
        &lt;ul class="list list-messages" id="list"&gt;


        &lt;/ul&gt;
      &lt;/div&gt;
</code></pre>

<p>And this is my js code :</p>

<pre><code>    &lt;script&gt;
        $(document).ready(function () {
            $(".navbar-title").html(localStorage.getItem("Provider"));

        $.ajax({
            type: 'Get',
            url: 'http://41.128.183.109:9090/api/data/getalllocations',
            success: function (data) {

            for (var i = 0; i &lt; 11; i++) {

$("#list").append('&lt;li class="list-message" data-ix="list-item"&gt;&lt;a class="w-clearfix w-inline-block" href="chat.html" data-load="1"&gt;&lt;div class="w-clearfix column-left"&gt;&lt;div class="image-message"&gt;&lt;img src="images/128.jpg"&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="column-right"&gt;&lt;div class="message-title"&gt;James White&lt;/div&gt;&lt;div class="message-text"&gt;Hey dude! We are waiting for you at the main station, we will meet you near to....&lt;/div&gt;&lt;/div&gt;&lt;/a&gt;&lt;/li&gt;');

                }

            }
        });
        });
    &lt;/script&gt;
</code></pre>

<p>Its not working . please advice</p>