function getRootWin(){   
    var win = window;   
    while (win != win.parent){   
         win = win.parent;   
     }   
    return win;   
}

05-11 13:13