function showHeading(headingId){ if (jQuery('#heading'+headingId).html() == ''){ //Needs a error if the connection drops or the output is fatal. jQuery.ajax({ type: "POST", url: "/ajax/getHeading.php", data: "headingId="+headingId, beforeSend: function(XMLHttpRequest){ jQuery('#heading'+headingId).css('display','block'); jQuery('#heading'+headingId).html('
Indlæser<\/div>'); }, success: function(msg){ jQuery('#heading'+headingId).html(msg); }, error: function (XMLHttpRequest, textStatus, errorThrown) { jQuery('#heading'+headingId).html('