How do I update the returnHtml variable from within the anonymous success function?
function getPrice(productId, storeId) {
var returnHtml = '';
jQuery.ajax({
url: "/includes/unit.jsp?" + params,
cache: false,
dataType: "html",
success: function(html){
returnHtml = html;
}
});
return returnHtml;
}