Sunday, May 13, 2012

Replace IFrame with DIV! example

sont be afraid - say no to IFrame! <html >
<head >
<script src="jquery/jquery-1.7.1.js" type="text/javascript"></script>
<script type="text/javascript">
   function GetDivInnerHtml()        
   {         
         $.get("/Page2.aspx",function(data){   //OR www.google.com
              $( "#divMain" ).html(data);
         });        
   }
</script>
</head>
<body onload="GetDivInnerHtml()">
      <div id="divMain"> </div>
</body>
</html>

No comments:

Post a Comment