I am trying to import one HTML page into another, but when I load or refresh the page, the HTML markup appears before the page fully loads. How can I fix this issue?
<head>
<script type="text/javascript" src="js/jquery-1.10.2.js" ></script>
<script>
$(function(){
$('.header').load("Header.html");
});
$(function(){
$('.first').load("leftpanel.html");
});
$(function(){
$('.second').load("banner.html");
});
</script>
</head>
<body>
<div class="header"></div>
<div class="main">
<div class="second"></div>
<div class="first"></div>
</body>