My menu disappears...

C

camelot

Hello,
I've got a problem and I hope someone could help me.
I have a page that contains frames. Below a piece of code:
....
<FRAMESET COLS="120,*">
<FRAME NAME="menu" SRC="menu.html" >
<FRAME NAME="main" SRC="main.html">
</FRAMESET>
....
The page menu.html contains the following code:
....
<a href="javascript:window.open('test1.pdf','main')" > doc1 </a>
<BR>
<a href="javascript:window.open('test2.pdf','main')" > doc2 </a>
.....
The problem is that when I click on frame "menu" the links "doc1" and
"doc2" the pdf is correctly loaded (through the plug-in) but the
content of the frame "menu" disappears and appears the inscription
"[object]". This does not happen if the links doc1 and doc2 are
realized without JavaScript.
This problem is the exemplification of a more complicate case where
the menu.html contains a tree menu that for each item you have to
specify a ref = "code". Inside it I put a javascript function to be
executed because I have to load a pdf inside a different frame.
The question is if I could avoid the disappearing of menu frame using
a different approach or a simply modification of my javascript code.
Could you help me?

Reagards,

Camelot
 
J

Jeff North

| Hello,
| I've got a problem and I hope someone could help me.
| I have a page that contains frames. Below a piece of code:
| ...
| <FRAMESET COLS="120,*">
| <FRAME NAME="menu" SRC="menu.html" >
| <FRAME NAME="main" SRC="main.html">
| </FRAMESET>
| ...
| The page menu.html contains the following code:
| ...
| <a href="javascript:window.open('test1.pdf','main')" > doc1 </a>
| <BR>
| <a href="javascript:window.open('test2.pdf','main')" > doc2 </a>
| ....
| The problem is that when I click on frame "menu" the links "doc1" and
| "doc2" the pdf is correctly loaded (through the plug-in) but the
| content of the frame "menu" disappears and appears the inscription
| "[object]". This does not happen if the links doc1 and doc2 are
| realized without JavaScript.
| This problem is the exemplification of a more complicate case where
| the menu.html contains a tree menu that for each item you have to
| specify a ref = "code". Inside it I put a javascript function to be
| executed because I have to load a pdf inside a different frame.
| The question is if I could avoid the disappearing of menu frame using
| a different approach or a simply modification of my javascript code.
| Could you help me?
|
| Reagards,
|
| Camelot

You can either place
<base target="main.html" />
within the menu.html header
or
<a href="javascript:window.open('test2.pdf','main')"
target="main.html" >
 
C

camelot

| Hello,
| I've got a problem and I hope someone could help me.
| I have a page that contains frames. Below a piece of code:
| ...
| <FRAMESET COLS="120,*">
| <FRAME NAME="menu" SRC="menu.html" >
| <FRAME NAME="main" SRC="main.html">
| </FRAMESET>
| ...
| The page menu.html contains the following code:
| ...
| <a href="javascript:window.open('test1.pdf','main')" > doc1 </a>
| <BR>
| <a href="javascript:window.open('test2.pdf','main')" > doc2 </a>
| ....
| The problem is that when I click on frame "menu" the links "doc1" and
| "doc2" the pdf is correctly loaded (through the plug-in) but the
| content of the frame "menu" disappears and appears the inscription
| "[object]". This does not happen if the links doc1 and doc2 are
| realized without JavaScript.
| This problem is the exemplification of a more complicate case where
| the menu.html contains a tree menu that for each item you have to
| specify a ref = "code". Inside it I put a javascript function to be
| executed because I have to load a pdf inside a different frame.
| The question is if I could avoid the disappearing of menu frame using
| a different approach or a simply modification of my javascript code.
| Could you help me?
|
| Reagards,
|
| Camelot

You can either place
<base target="main.html" />
within the menu.html header
or
<a href="javascript:window.open('test2.pdf','main')"
target="main.html" >

---------------------------------------------------------------
(e-mail address removed) : Remove your pants to reply
---------------------------------------------------------------- Hide quoted text -

- Show quoted text -

Thank you! The "base" solution is perfect!

Camelot
 

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

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,599
Members
45,175
Latest member
Vinay Kumar_ Nevatia
Top