Take the 2-minute tour ×
Web Applications Stack Exchange is a question and answer site for power users of web applications. It's 100% free, no registration required.

How can I send a HTML email having JavaScript using Gmail or Yahoomail to Gmail or Yahoomail?

share|improve this question
add comment

2 Answers

up vote 11 down vote accepted

You shouldn't - allowing JavaScript to run in a e-mail client would be a huge security risk.

I originally said "you can't" but it's been pointed out that some clients will execute the Javascript. So, hopefully Gmail and Yahoomail don't allow scripting for this very reason.

On a personal note, I think HTML in e-mails should be avoided to. What's wrong with plain text?

share|improve this answer
    
Sadly, many HTML capable mail clients will execute the Javascript. –  Cry Havok Oct 28 '10 at 11:48
    
@Cry Havok - perhaps I should change the answer to "You shouldn't". –  ChrisF Oct 28 '10 at 11:55
2  
@Cry Havok name one. –  Pekka 웃 Oct 28 '10 at 12:00
    
@Pekka, older version of Outlook Express did ISTR (since they just hooked IE) and I've a feeling Outlook did too once. Haven't checked recently whether that's still the case. –  Cry Havok Oct 28 '10 at 13:18
1  
"What's wrong with plain text?" - The same thing that's wrong with plain text web pages. –  SooDesuNe Oct 30 '10 at 19:37
add comment

Send a link to a web page and request that they manually click the link.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.