Hi frame experts c",) Hope you can help me out on this one
I've got a frameset (index.html) on my server (server A) defining two
frames. Left frame is named "menu" and contains a page (menu.html) which is
located on the same server while right frame is named "main" and contains a
page (main.html) which is located on another server (server B). This page
has a form named "f" with an element named "id". I want to access/read the
value of this element from the left frame, but I get an access denied error.
Can anybody please help me!
Just to test, I've put an exact copy of the page on server B, onto server A,
and then I have no problems accessing the value. I use the following code:
window.parent.main.f.id.value
I've also tested the frame structure (see the code below the line). When the
page in the right frame is located on server B, it seems like the whole
reference to the right frame is lost.
I also get the same results if I put all three documents on my computer and
fire up the site with
http://localhost/index.html and set the right frame
source to
http://127.0.0.1/main.html
I use IE
Any help is appreciated c",) Thanks!
Best regards Morten.
----------------------------------------------------------------------------
--------------
Show Frame Structure
1. Visit any web site with frames
2. Paste the following into the browser addressbar (remove any line breaks)
3. Watch a window popup which shows the frame heirarchy of the page being
visited
javascript
:function
dt0(W,N,fo,i){fo=eval(N);W.document.write('<li>'+f o.name+'['+fo.document.tit
le+'-'+fo.document.location.pathname+']');if(fo.length>0){W.document.write('
<ul>');for(i=0;i<fo.length;i++){dt0(W,N+'.frames['+i+']',undefined,0);}W.doc
ument.write('</ul>');}};function
dt(W,N){W.document.clear();W.document.write('<ul>' );dt0(W,N,undefined,0);W.d
ocument.write('</ul>');W.focus();};function
s(){window.open('','W').close();W=window.open('',' W','height=500,width=500,r
esizable');dt(W,'top');};s()
----------------------------------------------------------------------------
--------------