user1726950
user1726950

Reputation: 9

Can someone please solve this? (Basic HTML)

I am using this code to link an embedded .swf file to another page inside an iframe :

<div onmousedown="window.location.href='http://www.pagewhichopens.com'" height=26 width=100>
    <object height=26 width=100>
        <param name="movie" value="http://www.bcd.com/embeddedfile.swf">
        <param name="wmode" value="transparent" />
        <embed wmode=transparent allowfullscreen="true" allowscriptaccess="always" src="http://www.bcd.com/embeddedfile.swf" height=26 width=100></embed>
    </object>
</div>

But when I cick on the swf the another page opens inside that iframe only which I don't want, I want it to open in the whole browser... which can be done by inserting target="_parent", but where should I put it?

Upvotes: 0

Views: 92

Answers (2)

Quentin
Quentin

Reputation: 944498

Use top.location to set the location of the top frame or parent.location for the immediate parent. window refers to the current context (inside the frame).

Upvotes: 2

rsz
rsz

Reputation: 1161

To open some link in a new tab use target="_blank" to achieve this

Upvotes: -1

Related Questions