JQuery - append rather than replace content using .innerHTML?
<p>Below is a function that retrieves a users older wallposts, 16 at a time, and appends each chunk of 16 to the end of the current list in the div called "sw1".</p>

<p>It works fine, except in the case where there is currently a wallpost that contains a video/embedded object that is currently in the process of playing.
When we click on the button that calls the function below during the playback of an object in sw1, the below function seems to cause the entire content of sw1 to be removed, and then re-dumped.</p>

<p>Is it possible to modify the function below so that it merely appends new data to the end of sw1, rather than replacing the entire contents, killing any objects that are currently playing??</p>

<pre><code>function fetch_older_wallposts(u,lim){
var xhr = getXMLHttpRequest();

xhr.onreadystatechange = function() {
if (xhr.readyState == 4 &amp;&amp; (xhr.status == 200 || xhr.status == 0)) {

//document.getElementById( 'sw1' ).innerHTML.append( xhr.responseText );
document.getElementById( 'sw1' ).innerHTML += xhr.responseText;
}else{
document.getElementById( 'oaps_loading' ).innerHTML = 'loading';
}
};

xhr.open("POST", "script.php?u="+u+"&amp;lim="+lim, true);
xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xhr.send(null);
}
</code></pre>

<p>Any sort of assistance or guidance appreciated guys....</p>

<p>Thanks for all the usefull comments guys!</p>
