Answer the question
In order to leave comments, you need to log in
How to make iframe links external?
Hello!
There is an iframe, there is a site on wp that is loaded there
How to make it so that when you click on a link, a redirect occurs not in the iframe itself, but on the page where the iframe is located?
Answer the question
In order to leave comments, you need to log in
on the parent (your site):
or from an iframe:
<a href="" onClick=javascript:opener.document.location.href='/page2/'>родительскую страницу на page2</a>
Add to site in a frame in a block
<head>
...
<base target="_parent" />
...
</head>
var newBase = document.createElement('base');
newBase.target = '_parent';
window.frames[0].getElementsByTagName('head')[0].appendChild(newBase);
I would try getting all the iframe links and add http://domainname/link to the attributes.
But we need to see if it is possible to get all the links from it, and so on.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question