robn
Posts: 70
|
| Posted: 01/26/2007, 4:53 AM |
|
Hi all
I just discovered that the window.opener and window.close method does not work in IE 7, this is a major problem for me as several of the applications I have developed use this method to pass information back to a master form from a popup (see below)
window.opener.document.tblQualSoftSupport.ImpDoc.value=cid;
window.opener.focus();
window.close();
}
But now in IE7 this information is not passed back to the master form so the ImpDoc value in blank "". Is there any way round this or another method I could use? any help would be much appreciated.
Thanks in advance
Robn
|
 |
 |
robn
Posts: 70
|
| Posted: 02/05/2007, 3:16 AM |
|
I don't suppose anyone else has had this issue, or knows a way around it?
|
 |
 |
peterr
Posts: 5971
|
| Posted: 02/05/2007, 3:22 AM |
|
This example uses similar code and works fine for me with IE7: http://examples.codecharge.com/ExamplePack/PopUpList/PopUpList.php
Does it work in your IE?
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
robn
Posts: 70
|
| Posted: 02/05/2007, 6:06 AM |
|
Thanks Peter
Yes just tested your example and it works fine when using the (this) in the Setopenervalue. But I have a slightly different requirement I'm trying to pass through 2 values, one which is the documents ID (CID) and one which is the documents title (linkTitle). So the function looks a little like this.
function Setopenervalue(cid, linkTitle)
{
window.opener.document.tblQualJournal.DocID.value=cid;
window.opener.document.tblQualJournal.DocName.value=linkTitle;
window.opener.focus();
window.close();
}
with the onlick on the link containing onclick="Setopenervalue('{cid}','{linkTitle}')"
This works fine in IE 6 and below but in IE 7 I get an undefined return value.
When I use
function Setopenervalue(cid)
var IE = (document.all) ? 1 : 0;
if(IE) {
var cid = cid.innerText;
} else {
var cid = cid.text;
}
window.opener.document.tblQualSoftSupport.ImpDoc.value = cid;
window.opener.focus();
window.close();
}
with the onlick on the link containing onclick="SetOpenerValue(this);return false;"
this works fine in both IE 6 and IE 7. But I cant seem to be able to pass through 2 values in IE 7.
Any help would be much appreciated.
thanks
Rob
|
 |
 |
Jman
|
| Posted: 02/27/2007, 12:59 PM |
|
I am using multiple values as well in my "opener" code, I have found a work around for most of my JavaScript issues with IE7. Of course, my application is running on an intranet, so I am able to control these options.
(1) First, adding your URL to the clients trusted sites in thier security options seems to help.
(2) Second, I also loaded a tool that microsoft has available for download. Here is the link... http://go.microsoft.com/fwlink/?LinkID=70356
|
|
|
 |
|