0
是否有可能獲得先前的父窗口的ID,如果你有document.location.href="diffPage.htm?name="+string;
,其中字符串將每一次改變推出的子窗口?的document.getElementById在另一個窗口
基本上我有與id=favouritesTab
是去調用一個函數時diffPage.htm主窗口,叫main.html中。
我試圖window.parent.document.getelementById()
如
var favouritesScreen = window.parent.document.getElementById('favouritesTab');
if(favouritesScreen.style.display == 'inherit')
{
..so on
但它似乎並沒有在所有的工作。有誰知道這是否有解決方案?