Webphone multi page example

This is a demonstration to use the same webphone instance on multiple pages.
For example you can begin a call on page A, launch a new page (page B started from page A), see the webphone status also on page B, then hangup the call either for page A or page B
It is not limited to only 2 pages. You can launch as many pages as you wish and the same webphone instance will be shared across all pages.
Here we are just using the getEvents(callback) webphone api to display the webphone state on our "events" div, however you can implement any other functionality in the same way using the other callbacks.
For the sake of simplicity we are using the same html file also for second pages here (multipage_example.html), but you can use also different pages, just make sure to add the below multipage handling in all your pages.
For this example to work, you need to: You can open any number of windows/tabs and push the Call and Hangup buttons on any page (you can add more functionality in the same way as these are implemented in this example) Note: the webphone will be closed if you close the "main" page (from where it was started the first time), but if needed, it will auto start again on new pages.