title: Local JSON data to getJSON on URL
body: <p>I am using this script which reads some internal json data.</p>
  
  <p>The data is currently in the actual page.</p>
  
  <p>I need to change the code to use getJSON? so that it reads the json from an external page/url</p>
  
  <p>Here is the current full code:</p>
  
  <pre><code>&lt;script&gt;
  
  var data = [{"id": "1","title": "mytitle"}];
  
    var output = '';
  
   $.each(data, function(index, value){
          output += '&lt;li data-icon="false"&gt;&lt;a href="#"&gt;' + value.title + '&lt;/a&gt;&lt;/li&gt;';
      });
  
  
      $('#listview').append(output).listview('refresh');
  
  &lt;/script&gt;
  </code></pre>
  
  <p>How do I change the code so I can use external json code instead of this way for example adding getJSON to it?</p>