I basically need to show some information about the current game in a separate window, and I used to do it like this:
gWindow = window.open("", "", "width = 350, height = 300, location = no");
if (self.pl.guild != undefined)
{
gWindow.document.write("<p> Name: " + self.pl.guild.n + "</p>");
}
Now, I need that window to be a bit more complex… I’d like to have a pre-prepared page that I’ll just feed into it, I know how to do that, but I’d like to give that window arguments, or have the window itself be able to read them from the main page. How do you do that?
The newly opened window has a property, which refers to the main window:
Propeties defined on the
gWindowobject at the main page will also be defined at thewindow(globally) at the opened window, becausegWindowrefers to thewindowobject of the new window.