Jump to content
  • Advertisement
Sign in to follow this  
Super Llama

Javascript HTML include?

This topic is 3611 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have two domains; a free one with ASP.NET support, and a paid-for one without ASP.NET support. I'm trying to display parts of the ASP.NET site within the paid-for site without using IFrame (I want it to be raw html data, not inside a frame). Is there any way to do this? I tried using XMLHttpRequest, but it gave a permission denied error (can't communicate from one domain to another). I was trying to make an HTTP Get and simply use document.write() to output the data... but that makes a security error (it works with local pages though). Is there any IFrame alternative, or possibly a better javascript way to do this? I'm posting this here because this is the best programming site that I know XD

Share this post


Link to post
Share on other sites
Advertisement
It seems to the browser like one, but it isn't; I'm just trying to get data from my other site the way a browser does... I need ASP.NET support on the paid-for site but they don't offer it, so I got a freehosted ASP.NET site and I'm trying to copy the data. I know WHY its doing it, I just want to know if there's any way to do this! An IFrame without a frame, perhaps? A <P> or <span> tag with an src property?? Anything!

I can't make server or client side includes work properly either.

Perhaps I could make a script on the other domain to copy its own data to a jscript file where the first site could access it via <script src='blah'>?

An IFrame without a frame would be the best though, if there is such a thing.

Either that or I could port the entire ASP.NET site to a javascript site and put it on the main domain, but that would be very tedious.

I would just use <IFrame src="(asp.net site)" width="100%" height="100%"></IFrame> but that leaves an ugly border since the 100% tag leaves margins...

[Edited by - Super Llama on November 26, 2008 12:57:57 PM]

Share this post


Link to post
Share on other sites
What do mean by "I have two domains"? If you own both domain names you can have them point to the same ASP.NET-supporting server.

Share this post


Link to post
Share on other sites
Why don't you just redirect them to the appropriate page instead? It only takes 1 line: top.location.href = "insert_address_here";

Share this post


Link to post
Share on other sites
By two domains, I mean two servers; a free one and a not-free one. The not-free one has a watermark on the domain so I don't want to use that domain.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!