title: How To Get Json Data into Jquery Mobile Application
body: <p>I'm making basic "news" application in dreamviewer with Jquery Mobile.</p>
  
  <p>I made all design but now its time to get the Json data from my api server into my application.</p>
  
  <p>Here is my api server link ; f.e. "http:/mywebapiurl"</p>
  
  <p>i think i need to write Jquery function about getJson but i dont know how to make it ?</p>
  
  <p>How will i put it in to my listview with small article picture, articletitle and articleheadline ?</p>
  
  <p>Here is sample of my listview which i'm going to show the news coming from Json.</p>
  
  <pre><code>&lt;body&gt; 
  &lt;div data-role="page" id="home"&gt;
  &lt;div data-role="header"&gt;
      &lt;h1&gt;Post Mobile&lt;/h1&gt;
  &lt;/div&gt;
  &lt;div data-role="content"&gt;   
      &lt;ul data-role="listview" data-inset="true"&gt;
                       &lt;li&gt;&lt;a href="#headline"&gt;
           &lt;img src=ArticlePicture" class="ui-li-has-thumb"/&gt;
           &lt;h3&gt;ArticleTitle&lt;/h3&gt;
           &lt;p&gt;ArticleHeadline&lt;/p&gt;
                       &lt;/a&gt;&lt;/li&gt;
                  &lt;/ul&gt;       
  &lt;/div&gt;
        &lt;div data-role="footer"  data-position="fixed"&gt;
        &lt;h4&gt;&amp;copy; funky app &lt;/h4&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>
  </p>
  
  <p>here is the code sample i tried ;</p>
  
  <pre><code>    &lt;script&gt;
    $(document).ready(function() {
     $.getJSON("http://mywebapiurl", function(data) {
        var result= "";
        $.each(data.LatestNews, function(index, value) {
  result+= "&lt;ul&gt;&lt;li&gt;&lt;a href='#'&gt;&lt;h3&gt;"+value.TITLE+"&lt;/h3&gt;&lt;p&gt;"+value.SPOT+"&lt;/p&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;"; 
  });
      $("#articleContainer").html(result);
  })
  });
  &lt;/script&gt;
  </code></pre>
  
  <p>waiting your answer.</p>
  
  <p>Thank you very much.</p>