How to change the window.location of a frame

5

I wanted to know if you can enter a target here:

window.location='www.google.com';

I do not want to open a new page, otherwise I would use window.open . I want to use target="topFrame" to control a player.

I'm using an old little thing (frameset). I'm using this way in the <a href="system/radio/on.php" target="topFrame"> link.

    
asked by anonymous 17.07.2014 / 18:33

1 answer

5

Well, here is the solution I found.

How I was using

<a href="system/radio/on.php" target="topFrame"> <div class="icone_som_um"> </a>

How I'm using it now

function tocar() {
    top.frames['topFrame'].location.href = 'system/radio/on.php';
}

I'm firing the function in js so

<div class="icone_som_um" onClick="tocar()">
    
18.07.2014 / 04:35