We help IT Professionals succeed at work.

How to communicate between web pages (2 different browsers from 2 different web servers) on same client ???

aquila98
aquila98 asked
on
1,045 Views
Last Modified: 2007-12-19
Hello

I have this strange requirement and I have no idea how best to proceed... So I figured better to ask the experts ;-)

On a client desktop there is two distinct instances of an internet browser (IE6, IE7 or Firefox). Meaning that in the taskbar I see the two browsers.

Now in each browser there is running an application from a web server in which the user was logged into an oracle database (same instance on yet another server).

One web server is running Oracle EAM on Apache and the other is running IIS6 and a custom web application (C# and ASP.Net framework 1.1 soon to be 2.0)

My problem is that I must send a message from one web browser to the other so that information on a page shown in one can be updated if it is changed in the other. I don't think any session, application or server variables can help since I am dealing with two different servers...

How can I send an equivalent of a windows sendmessage() or postmessage() in web setup such as this????

Thanks for any hints, sample code or links... I know it must be pretty easy stuff to do but I have no idea where to start looking!!! ;-)





Comment
Watch Question

if the second window was opened by the first you can use javascript to communicate between the two. if the two were opened independently by the user, i think you are out of luck, they will not be able to communicate directly to each other.

You will probably need to develop a messaging server that both applications can ping frequently. There might be something more eligant

Author

Commented:
I would think the user will open either one first then the other...
I guess I can arange a kind of portal or login page that would then open the other two in a specified order...
I could issue two succesive call to load each url (http://server1... and http://server2...) once the login info is inputed...

But what kind of javascript would be needed? and where should I put this code in my page?

thanks
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Author

Commented:
Hello Rob

If I can manage to have one window open the other (say A opens B) I can using Javascripts establish a communication between the two windows... A will know B...
But how about B? how will it know who openned it (or called the url) ?

Do you have an example of this kind of cummunication between default.aspx ?

thanks
Artysystem administrator
Top Expert 2007

Commented:
'in each browser there is running an application from a web server' what kind of application? Java?

Author

Commented:
On one is a arcgis server application which we develop (VB .Net vsscript mostly).
On the other is Oracle Enterprise Asset management webforms which we customized by adding a button (java script).

both must know the other window and be able to exchange 'messages'

webapp A can open webapp B (or the other way around but if that is too complex I can make it so that it is always webapp A that starts firts then it opens webapp B)

I guess it the trick is when A open url B then B knows its parent then there is some java way to transfer data (send messages or even objects from java to vb????)

thanks, as I have guessed already I am new to this javascript stuff :/
> .. must send a message from one web browser to the other ..
This is impossible due to the nature of HTTP (most people will think and rely in;-).
Hence you have to implement a push and pull logic in both browsers, most proper would be to use AJAX (which requires JavaScript browser-side) as already suggested.

There's another way to "send a message" or "remote control" another browser connected anywhere to the internet from your browser, but that's strong hacking stuff (illegal, somewhere, somehow, sometimes) for which I wont post a link. The keywords to that are browser war farmework, if you understand what I mean. All those techniques use JavaScript under the hood, obviously ('cause/hence it is a security nightmare;-)

Author

Commented:
I see... So the correct way to implement this is via a ajax webservice

I'll look that up and try and find sample to start me up :)

Point wise, it's kind of hard but I think adnix should get most of the 100 points... Provided there is no objections from all who so kindly replied to this thread...
> .. So the correct way to implement this is via a ajax webservice
no, it's just one way to do it ;-)
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.