cancel
Showing results for 
Search instead for 
Did you mean: 

How to make a comunication between Applet & JSF Backing

mohammed_amr
Champ in-the-making
Champ in-the-making
Dear Gurus,

I have the following case

- i have a button inside an alfresco JSP page and that button will invoke an Applet.
- Applet functionality limited to acquire an image from a scanner.

Now i need to save this image as a node on the alfresco repository, so i need away to communicate with JSF backing bean to use alfresco services to save the image as a node.

But how to open a communication between Applet (client-side) and JSF Backing bean ?

after googling something like that i see several forums talks about Applet communication with Servlet and then servlet will gain a certain bean.

but for you information, most of forums talks about communication with (null) FacesContext which is may be not a proper way to communicate.

What is the proper way of communication and if Applet-Sevlet is the only way how can i communicate with the repository ?

Thanks
Mohammed Amr.
Senior System Developer.
1 REPLY 1

gyro_gearless
Champ in-the-making
Champ in-the-making
Not sure if this possible with JSF (admittedly, i understood that JSF stuff only to a certain extent), but i'd rather use a more AJAXish approach:

- Make a webscript to receive your scanned documents and possibly metadata.

- Make your applet call the webscript (maybe using Commons Httpclient) and upload your scanned documents (you may do this in the same fashion as AJAX calls are made from Javascript, i think there is a good tutorial on the Sun errr. Oracle developers site…)

HTH
Gyro