Microsoft KB Archive/884697

= Internet Explorer frame.frames properties of an object do not retain their values after upgrading to Windows XP Service Pack 2 (SP2) =

Article ID: 884697

Article Last Modified on 8/13/2007

-

APPLIES TO


 * Microsoft Windows XP Service Pack 2
 * Microsoft Windows XP Service Pack 2

-





Important This article contains information about modifying the registry. Before you modify the registry, make sure to back it up and make sure that you understand how to restore the registry if a problem occurs. For information about how to back up, restore, and edit the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows Registry



SYMPTOMS
When you install Microsoft Windows XP Service Pack 2 (SP2), a new object caching feature is also installed. When you compare the values of the two frame.frames properties of an object in Microsoft Internet Explorer, the results may be incorrect, or the values may not be retained.



CAUSE
In Windows XP Service Pack 2, the frames object is now wrapped with a security wrapper. When the new object caching feature is enabled, this security wrapper is applied. Therefore, access to all cached objects is blocked. This may cause the frames object comparison to return false even though the frames are equal.



RESOLUTION
Warning If you use Registry Editor incorrectly, you may cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that you can solve problems that result from using Registry Editor incorrectly. Use Registry Editor at your own risk.

To resolve this problem, you can use either of the following methods to restore or to replicate the original functionality:   You can compare the frames objects by name, as in the following sample code: a.name == parent.frames[1].frames.name  You can change the registry by using the following registry setting. The following registry setting reverts the object caching to pre-Service Pack 2 behavior. The registry change has to be performed on each client. We do not recommend this method.

Note Restart your computer after you modify the value data of this registry key.



STATUS
This behavior is by design.



Steps to reproduce the problem
  Create an HTML page that is named Test1.html. Put the following code in the Test1.html page: Test

 <frame name=&quot;frame1&quot; title=&quot;&quot; src=&quot;about:blank&quot; marginheight='0' marginwidth='0' noresize scrolling='No'> <frame name=&quot;frame2&quot; title=&quot;&quot; src=&quot;about:blank&quot; marginheight='0' marginwidth='0' noresize scrolling='No'> <frame name=&quot;frame3&quot; title=&quot;&quot; src=&quot;test2.html&quot; marginheight='0' marginwidth='0' noresize scrolling='No'>

</li>  Create a second HTML page that is named Test2.html. Put the following code in the Test2.html page : <script language=&quot;javascript&quot;> var a; function frames {  a = parent.frames[1].frames; } function boo {     if (a== parent.frames[1].frames) alert(&quot;match &quot;); else alert(&quot;no match &quot;); } <body onload=&quot;frames&quot;> <input type=&quot;button&quot; onclick=&quot;boo&quot; value=&quot;Test&quot;>

</li> Put Test1.html and Test2.html in the same folder.</li> Double-click Test1.html, and then click Test.</li> On a computer that is running Windows XP Service Pack 2, you may receive the following message:

no match

On a computer that is running a version earlier than Windows XP Service Pack 2, you may receive the following message:

match

</li></ol>

<div class="references_section">