Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

can u include at runtime ? 2

Status
Not open for further replies.
Sure, using IE and the MSXML objects:
[tt]
<html>
<head>
<script>
function getsite(){
var yahoo = new ActiveXObject(&quot;Msxml2.XMLHTTP.4.0&quot;);
yahoo_Open(&quot;GET&quot;, &quot; false);
yahoo.Send();
document.getElementById('displayIt').innerHTML = yahoo.responseText;
}
</script>
</head>
<body onload=&quot;getsite();&quot;>
<h1>Yahoo Web site to appear below this:</h1>
<div id=&quot;displayIt&quot;></div>
</body>
</html>
[/tt]

But there is no cross-browser standard way of doing this.

Never be afraid to share your dreams with the world.
There's nothing the world loves more than the taste of really sweet dreams.
 
What do you mean by &quot;runtime&quot;? If you mean &quot;when the page is loaded&quot;, you can do it at the server (which thus works in ALL browsers). See faq253-3309 and faq253-2000 for more information on Server Side Includes.

If you mean &quot;after the page is loaded, in response to actions by the user&quot;, you're in the realm of Javascript - which dwarfthrower knows more about than me. It's certainly more prone to browser differences, and won't work at all for any visitors who have JS switched off.

-- Chris Hunt
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top