PDA

View Full Version : Open email window when clicked



daidai
April 13th, 2008, 04:44 PM
Ive created a sprite and added a mouse click event with the listener as

private function sendEmail(e:MouseEvent){
var _url:URLRequest = new URLRequest("mailto:email@email.com"); navigateToURL(_url, "_blank");
}is there a better way? as this acts as a popup which gets blocked and opens (in firefox) an unnecessary window (tab).
thanks
dai

nikefido
April 13th, 2008, 04:50 PM
try navigated to "_self" instead of blank. that should tell the browser to just try to open the users mail program. if it doesn't find a mail program, it'll do nothing as usual. i think.

daidai
April 13th, 2008, 04:52 PM
thanks nikefido, its done the trick :)