You should use the callback functions of the .fadeOut() and .load() functions. At the moment you are fading-out, adding HTML, and then fading-in all at the same time.
Try:
//add event handler to click event for the #content element $('#content').click(function() { //cache this element var $this = $(this); //fadeOut the element $this.fadeOut(function () { //after fadeOut is done, change it's HTML $this.load('about.php', function () { //now fadeIn the new HTML, this is in the callback for the `.load()` //function because `.load()` is an asynchronous function $this.fadeIn(); }); }); });
The reason I nested all the callback functions is so that each process can complete before the next one is run. First the .fadeOut() is allowed to complete, then the .load() is allowed to grab the data and place it in the DOM, then we .fadeIn() the element with the new HTML.