Javascript and frames

A

Atz

How to open existing page in the mainFrame.

My start page has 4 frames and on the left side are menu links in table,
with some effects .

Like:
<td height="23" align="center" valign="center" bordercolor="#666666"
bgcolor="#E1E1E1" style="cursor:hand" onclick="window.location='page1.html'"
onmouseover="bgColor='#FFFFCC'" onmouseout="bgColor='#E1E1E1'">

<a href="page1.html" target="mainFrame" class="tditem"> Search</a>

</td>

If i use this code the page is loaded into same page and not in mainFrame.

I tryed with this :
onclick="parent.mainFrame='page1.html'"

but there is no effect...

Thanx in advance
 
V

Vjekoslav Begovic

Can't you just remove onclick event handler?

Or, if you must, you can put this:

onclick="parent.mainFrame.location='whatever.htm'"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,077
Messages
2,570,569
Members
47,205
Latest member
KelleM857

Latest Threads

Top