CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4

Threaded View

  1. #1
    Join Date
    Aug 2004
    Location
    Land of sunshine and June Gloom
    Posts
    171

    Unhappy Swapping frames causes zero widths in Firefox/not working in NN

    Hi,

    I have an application that has 2 navigation menus that can be shown or hidden when buttons are clicked. Each menu is in a separate frame in a frameset document. If one menu is shown and the other hidden, then I need to put the hidden one into the leftmost column of the frameset (which requires changing frame order) and set its width to 0 using the cols attribute of the frameset.

    In order to determine which ones are shown or hidden, I need to get the widths of each frame. To swap frames, I use insertBefore() on the frameset object. When I do insertBefore() in Firefox, the frames get swapped, but the page flashes innerWidth attribute no longer gives the correct value for the frames. In Netscape the insertBefore() does not swap the frames at all. I can only get it to work in IE.

    I have made a few web pages that show this error. In the attachment, you should notice that the innerWidth of both frames becomes 0 after hitting the 'Swap Frames' button twice.

    I have attached the sample HTML files here. Main.html is the frameset document. Please tell me if you know how to make it work for Firefox 1.5.0.7/Netscape 8.1.

    Thanks in advance
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured