title: Show content from external php file with GET parameter inside div
body: <p>Im struggling to make links for files appear on same page inside DIV.
  Simply nothing happens when I a href click link, no links appear.. however I can see links when I'm going directly to example.com/ajaxdetails.php?id=OneOftheIDs
  Here is mine main HTML file:</p>
  
  <pre><code>&lt;script src="/jquery-1.11.2.min.js"&gt;&lt;/script&gt;
  &lt;script&gt;
  function getSummary(id)
  {
     $.ajax({
  
       type: "GET",
       url: "detailsajax.php",
       data: "id=" + id,
       success: function(data) {
            $('#returned-details').html(data);
       }
  
     });
  
  }
  &lt;/script&gt;
  </code></pre>
  
  <p>PHP part:</p>
  
  <pre><code>foreach ($pirmiRezai as $key=&gt;$rezultatas)
      { $i++;
      echo '&lt;div class="r"&gt;
      &lt;a href="javascript:void(0);" onclick="getSummary('.$rezultatas['ID'].')"&gt;'.$rezultatas['desc'].'&lt;/a&gt;
      Some unrelated php code here
      &lt;div id="returned-details"&gt;&lt;/div&gt;
      &lt;/div&gt;';
      if($i&gt;=10)
      break;
      }
  </code></pre>
  
  <p>And the detailsajax.php file contains simple textarea with returned download link from database for specific ID (detailsajax.php?id=random). I need that html code with returned download link to appear inside returned-details DIV next to a href that was clicked.
  Hope its clear.</p>