• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

How to invoke client side applets from a server side web application?

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys,

I don't know if I'm in the right thread to post this but I figured that I should post it here since my question it involves Web technologies (HTML, JavaScript, JSP and such), but on the other hand maybe I'm supposed to post this in the Applet thread?..

Anyways, my question is...

How do I invoke client side applets from a web application? (Servlets)

Thanks,
Vince
 
Rancher
Posts: 1337
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Generally, you can't. The applet needs to make contact with the server. What specific problem are you trying to solve?
 
Vinvin Parpar
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Lester,

Thanks for the quick reply, you see I've tried doing this with ActiveX and it works,
but our requirements changed so I no longer have the option to use IE as my web browser.

What other options could I use to replicate the behavior of ActiveX on other web browsers like Firefox and Google Chrome, any suggestions?

Thanks again,
Vincent
 
Lester Burnham
Rancher
Posts: 1337
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ActiveX is a technology that allows you to run just about every code you want in an IE browser instance, generally without much in the way of security. If that's acceptable, then you can sign the applet and have it execute any code you want, including one that opens a ServerSocket and listens for incoming HTTP requests.

The difficulty, though, is how the web server will get to know the IP address of the browser - how did that work with whatever ActiveX control you were using? And, of course, the client machine -and any firewall in between client and server- must allow incoming connections.
 
Vinvin Parpar
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I see, so If I embed a signed applet and use ServerSocket I'll be able to invoke applications (executable JAR for example) from the client side?

Here's the code I used back then when we were still testing ActiveX and when we were allowed to use IE:



As you can see I created a simple (just for testing) function call to a javascript just to invoke the JAR placed on the client side.

Thanks,
Vincent
 
First, you drop a couch from the plane, THEN you surf it. Here, take this tiny ad with you:
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic