I've been thinking of developing a web application using HTML and JavaScript for a little while now, but I've hit a wall during my ponderings. I want to be able to connect (long-term, not briefly) to a remote host with this app, one which is unfortunately not the server that the page was requested from.
From what I've read, JavaScript can't support long-term connections, and furthermore it won't request from anywhere that's not the domain the page was downloaded from. I considered hidden Java or Flash objects, but Flash seems to cost money, and Java requires a signed applet (and I don't know whether it's worth getting it signed).
The only solution that I think could work is using my server as a proxy to the others (through an unsigned Java applet?), but I really don't want to do that if I can help it. Is that my only realistic option, or are there other solutions I haven't considered yet?
(I considered asking on one of the other SO-alike sites, but StackOverflow seemed most apt, since this is largely a programming and design issue.)