|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
||||
|
||||
|
ASP/Javascript question
Hi!
I have 3 frame (top, middle,bottom). The middle page opens a popup after 2 minutes. The popup box is supposed to submit a form (named form) on it's opening page after 2 more minutes. My problem is when I try to submit that form from the popup I get the object not found or supported error. The code I am using to get the middle pages form to submit from the popup is . . . Code:
opener.document.form.submit(); Any ideas? Andrew |
|
#2
|
|||
|
|||
|
Code:
opener.parent.frames["middle_frame"].form.submit()
__________________
- Rogier Doekes |
|
#3
|
||||
|
||||
|
When using that code I get;
Object doesn't support this property or method Any ideas? Andrew |
|
#4
|
|||
|
|||
|
Code:
window.opener.parent.frames["middle_frame"].document.forms["name_form"].submit() that's the best I can do. |
|
#5
|
||||
|
||||
|
I got the same error. Might there be something that I am missing on the frame pages themselfs?
Andrew |
|
#6
|
|||
|
|||
|
did you name the frames on the frameset page?
|
|
#7
|
||||
|
||||
|
Yes, here's the code for that...
Code:
Response.Write "<frame src=""multi.asp"" name=""mainFrame"">" & chr(13) I have been replacing your ["middle_frame"] with ["mainFrame"] Andrew |
|
#8
|
|||
|
|||
|
The same here
Have you been able to reslove your problem? I have also tried the code as suggested above and reached the same deadlock.
|
|
#9
|
|||
|
|||
|
Maybe...
Follow me on this. I admit that I am propably barking up the wrong tree but anyway.
When attempting to refrence a function from a pop-up (where the function is located in the "opener" document inside a frame) through the standard - window.opener.my_function() method, I get an "Object does not support...." error. I had a look at the following - window.opener.name - and this returned "mainFrame". Thus - window.opener - was actually refrencing the frame. Not the document loaded inside the frame. In other words the basic code attributed to the frame itself rather than the document that exists inside the frame that created the pop-up and has the function I'm trieng to access. When working outside frames, it's a walk in the park.Tricky one this though. When working outside frames, it's a walk in the park. |
![]() |
| Viewing: Dev Articles Community Forums > Programming > JavaScript Development > DOM frame/window/opener reference problem |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|