We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

Embed java applet in html code in email, display a picture if the applet is blocked

supersizeit
supersizeit asked
on
Medium Priority
417 Views
Last Modified: 2007-12-19
Hello, I would like to embed a java applet within an HTML page and send it over email.  Specifically the applet calls a streaming video java player. I

In many email clients (such as later versions of Outlook) I get a security warning stating that "Your current security settings prohibit running ActiveX controls".

I would like the following process to happen but have no experience in Java at all:

Is it possible to sign the applet as safe?
If not I would like the applet to run, if the applet can not run I would like an image displayed - I.E. A click here to play this video image.  If it is plain text only I would like a link to a replica web page displayed in its place.

Is this possible or if not what is the next best solution?


 
Comment
Watch Question

Mayank SPrincipal Technologist
CERTIFIED EXPERT
Commented:
You can sign the applet of course (http://www.mindprod.com/jgloss/signedapplets.html, http://personal.vsnl.com/sureshms/javasign1.html), but you cannot send embed it in the HTML and send with the e-mail directly. You will need to attach it to the e-mail as a separate file.

>> If not I would like the applet to run, if the applet can not run I would like an image displayed - I.E

I think that would require some programming at the client-end.... not sure, though.

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
Sorry I forgot to say that the applet calls the code from the internet therefore I should not need to attach the applet? I.E. the .jar and .class files are on the internet.
Mick BarryJava Developer
CERTIFIED EXPERT
Top Expert 2010

Commented:
doubt any mail readers can run an applet, a better approach may be to include a link in your email which points at a page conteining the applet (on a jnlp file if you want to use web start)
Siva Prasanna KumarPrincipal Solutions Architect
CERTIFIED EXPERT
Top Expert 2006

Commented:
I think you can just simply send the HTML page having the Embedded Applet as an Attachment for the mail so that when user opens up the Attachment the file will automatically open it in a web browser where the Applet will start running.

Thank You.
Mayank SPrincipal Technologist
CERTIFIED EXPERT

Commented:
Yes, make sure that the applet is downloadable from a server.

Author

Commented:
I am going to rephrase the question:

I already can run the java applet embedded in an email.  In some versions of Outlook and other mail clients the new security settings block the applet from running.  One such warning in Outlook XP and 2003 is: Your current security settings prohibit running ActiveX controls".

How I have done this: The email contains embedded html links to images and the applet are loaded from my web server.

What I would like to do: If the applet can not load due to security settings is display an image instead of loading the applet code.  This can then link to a copy of the html page on my web server.

If the mail client only supports plain text then I will just put a link directly to this copy of the web page.
Java Developer
CERTIFIED EXPERT
Top Expert 2010
Commented:
try putting the link inside the applet tag

<applet ......>

   <a href="somewhere.html">Alternate link</a>

</applet>
Mayank SPrincipal Technologist
CERTIFIED EXPERT

Commented:
>> If the applet can not load due to security settings is display an image instead of loading the applet code

That might actually be programming or customization at the mail-client (like Outlook).
Mayank SPrincipal Technologist
CERTIFIED EXPERT

Commented:
Any reason for a C?
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*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.