How to stop websites going out of frame.

for example:- I got website Which goes out of iframe tag

<iframe src="http://muscleasylum.com" height="100%" width="100%"  ></iframe>

Recommended Answers

What do you mean by 'go out' of the ifram tag? Is it not restricted to the iframe size, is that it?

Jump to Post

You are going to load a url into an iframe, and if it doesn't load for some reason(broken) you want to try and load another url? Is that it?

Jump to Post

All 5 Replies

What do you mean by 'go out' of the ifram tag? Is it not restricted to the iframe size, is that it?

It means instead displaying in, <iframe src=""> </iframe>
It is redirected to it's original domain.

(out from iframe to original domain. it is frame break)

You are going to load a url into an iframe, and if it doesn't load for some reason(broken) you want to try and load another url? Is that it?

No,

Website (url) must be displayed inside <iframe src=""> </iframe>

<iframe src="http://muscleasylum.com" height="100%" width="100%"  ></iframe>

Check this site on localhost. When this site opens inside iframe then after few seconds it is redirected automatically to http://muscleasylum.com

I want to stop this. Url must be displayed inside iframe.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.