4 ms·
If I understand what you're saying correctly, I don't believe you can invokee a constructor defined in one window within another window ever. Javascript code i
by ben336 13y ago
If I understand what you're saying correctly, I don't believe you can invokee a constructor defined in one window within another window ever. Javascript code is sandboxed to its current window/session in all browsers. You can't have multiple windows interacting with each other without some form of server-side code being involved. For what you're talking about (a web framework that has real time communication capabilities and can manage updates across multiple instances of the application on the same machine in different windows), you'll need to involve more than client side javascript. Unless you're talking about using Node.js, which you don't mention here.
- euroclydon 13y agovar win = window.open(some_url_on_the_same_domain); or var parent = window.parent; Now, you can access global variables on either parent or win.
- ben336 13y agooh cool. In my head when I see that I just think spammy popup :) I can't recall seeing it used for a legitimate purpose. But yeah that would accomplish what you're describing.