posted 1 month ago
I'm working on a workaround with a synch'ing parent window, child window and grandchild window. I want to refresh the parent from the grandchild in case the child window is closed and the opener chain is broken. I figured on setting a localStorage variable, my_variable, in the grandchild (when it's opener, child, is closed) and putting the following in the parent onload...
I've verified my_variable value by adding localStroage.getItem("my_variable") to a button on the parent. So even when child is closed, the localStorage value does get to the parent. So I think the problem is with capturing the onstorage event. But it seems so straightforward and the parent onload executes to completion, i.e. the above throws no error. i should add this is legacy IE11 rendering as IE 9, but everything I've read said that code should work.
the target parent is within an iframe so i also tried...
and nothing. I've run the wsschools tutorials in the same browser with the above and it works there. I am so frustrated. Thank you very much for any ideas.