dialog content refresh delays

dialog content refresh delays


Hi,
I have a page with a list of products. A link on each product
generates a diaolog containing more information about the specific
product. When I click on a second dialog link after closing the
first, the content from the first appears for a few seconds while the
contents from the second product loads.
Is there a way to show a loading image and/or clear the data from the
first dialog?
The
<div class="previewLink" style="display:none;">
<a href="/browse/f_quick_buy.jsp?productId=300994401&pdpUrl=//
300994401/detail.html" ></a><img src="http://www.mysite.com/media/
templates/images/list_page/preview.gif" alt="preview"/>
</div>
             <script type="text/javascript">
$(document).ready(function() {
$(".productContainer").mouseover(function(){
$(".previewLink", this).show();
}).mouseout(function(){
$(".previewLink", this).hide();
});
$(function() {
$("#Preview").dialog({
autoOpen: false,
bgiframe: true,
modal: true,
height:400,
width:572,
draggable: true,
resizable: false
});
});
$(".previewLink").click(function() {
var uri = $(this).children("a").attr("href");
$.get(uri,function(data){
$("#Preview").html(data);
});
$("#Preview").dialog("open");
});
});
</script>
I'm using jquery-1.3.1.js and the most current stable
jquery.ui.all.js