Solved

Embedding a website within a website, and having it stay there

Posted on 2009-05-11
2
642 Views
Last Modified: 2012-05-06
A previous question/solution shows how to embed one website within another.  I have a similar situation, but the previous solution doesn't work to the extent I need.

I want to offer visitors to my site the opportunity to play around with a beta website, and then I want to ask them a few questions about what they think.  I want to embed the beta site on a page and have them be able to move around all they want on the embedded site without ever leaving the original site.  Using the previously provided solution, as soon as a link is clicked on the embedded webpage, the entire browser window goes to the clicked link.  I need people to stay put in the main "window" while they are free to surf around the "inner" window.  Hopefully that makes sense.

Thanks ahead of time!

TLG
0
Comment
Question by:TheLinkerG
2 Comments
 
LVL 12

Expert Comment

by:alien109
ID: 24356961
as long as your links aren't targeting _top or _parent you should stay in the iframe. can you show the implementation that isn't working for you?
0
 
LVL 1

Accepted Solution

by:
TheLinkerG earned 0 total points
ID: 24380564
Well, I think I've answered my own problem.  

Alien109, I was NOT targetting anything.  The IFRAME I was using looked like this:

<iframe src="http://www.espn.com" width="800" height="600"></iframe>

It looked fine at first, but as soon as I clicked a link it took over the entire window.  Since I'm going to be showing a mocked-up website that I control, I was able to fix it by modifying that code:

<iframe name="subwin" id="subwin" src="http://www.espn.com" width="800" height="600"></iframe>

In the mocked-up html, every link includes target="subwin" and that seems to work fine.  Anybody know how to fix it if I can't control the link targets?

Thanks again in advance... again...

TLG
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Does your audience prefer people in photos or no people? How can you best highlight what you’re selling? What are your competitors doing, and what can you do that is different and unique from them?  Continue reading to learn how to make your images …
There’s a good reason for why it’s called a homepage – it closely resembles that of a physical house and the only real difference is that it’s online. Your website’s homepage is where people come to visit you. It’s the family room of your website wh…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question