Hi Im looking for a way to open all links (in a child window) in the parent window
instead. I want this to happen Automatically because links in my child are called from the parent but I cannot alter link targets.
<base target="x">(in child head tags) dont work, though some will launch a new window.
I found this code idea that does work (see below) but I have no way of assigning the 'loadinparent' attribute to my childwindow links. Can I do that with javascript?
e.g.
if getelementbytag name==(a)
then (a) = ('this attribute')
}
what works (head of child)
link in child must be
instead. I want this to happen Automatically because links in my child are called from the parent but I cannot alter link targets.
<base target="x">(in child head tags) dont work, though some will launch a new window.
I found this code idea that does work (see below) but I have no way of assigning the 'loadinparent' attribute to my childwindow links. Can I do that with javascript?
e.g.
if getelementbytag name==(a)
then (a) = ('this attribute')
}
what works (head of child)
Code:
<script>
function loadinparent(url){
self.opener.location = url;
}
</SCRIPT>
Code:
<a href="javascript:loadinparent('http://www.google.com.au', true);">Google</a>
Comment