我們在projet中使用的是一個打開mailto:鏈接的彈出窗口,它是我們發現在默認郵件客戶端中編寫郵件的唯一方式,該郵件客戶端適用於所有郵件客戶端(至少我們所有的客戶端)。
var addresses = "";//between the speech mark goes the receptient. Seperate addresses with a ;
var body = ""//write the message text between the speech marks or put a variable in the place of the speech marks
var subject = ""//between the speech marks goes the subject of the message
var href = "mailto:" + addresses + "?"
+ "subject=" + subject + "&"
+ "body=" + body;
var wndMail;
wndMail = window.open(href, "_blank", "scrollbars=yes,resizable=yes,width=10,height=10");
if(wndMail)
{
wndMail.close();
}
似乎無法在IE 8中工作。根據調試器,wndMail爲空。 – 2009-11-03 16:41:36
很抱歉聽到這個消息。它來自使用IE6的舊項目。隨意編輯以提高:) – 2009-11-03 17:11:37