欧美激情网,国产欧美亚洲高清,欧美屁股xxxxx,欧美群妇大交群,欧美人与物ⅴideos另类,区二区三区在线 | 欧洲

知識學(xué)堂
  • ·聯(lián)系電話:+86.023-75585550
  • ·聯(lián)系傳真:+86.023-75585550
  • ·24小時手機(jī):13896886023
  • ·QQ 咨 詢:361652718 513960520
當(dāng)前位置 > 首頁 > 知識學(xué)堂 > 網(wǎng)站建設(shè)知識
網(wǎng)頁Javascript提交OutLook發(fā)送郵件
更新時間:2012-01-20 | 發(fā)布人:本站 | 點擊率:439
注意的幾個地方:

默認(rèn)發(fā)送格式為表單名稱=內(nèi)容.
所以在上面我做了兩個表單,先組合好內(nèi)容,然后發(fā)送,這樣就只有一個表單,而且內(nèi)容前面有說明(表單的說明)

表單的屬性設(shè)置,增加enctype="text/plain"(是以文本方式發(fā)送),或者 ENCTYPE="multipart/form-data"(是將文本打包成附件**.ATT的附件)
<form name="frmEmailOutLook" action="" method="post" enctype="text/plain">

發(fā)送表單action的格式
mailto:目的郵件地址?subject=郵件主題&Bcc=轉(zhuǎn)送(不記得了)&cc=抄送

以下是引用片段:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>網(wǎng)頁Javascript提交OutLook發(fā)送郵件</title>
</head>
<script language="javascript">...
function toOutLook()...{
  var objFrm = document.frmEmail;
    var objFrmOutLook = document.frmEmailOutLook;
    var msg = "";
    msg += "姓名: " + objFrm.name.value + "  ";
    msg += "電話: " + objFrm.phone.value + "  ";
    msg += "網(wǎng)址: " + objFrm.website.value + "  ";
    msg += "主題: " + objFrm.subject.value + "  ";
    msg += "內(nèi)容: " + objFrm.message.value + "  ";
    objFrmOutLook.message.value = msg;
    objFrmOutLook.action = "mailto:sundysea@hotmail.com?subject=" + objFrm.subject.value;
    objFrmOutLook.submit();
}
</script>
<body>
<form name="frmEmailOutLook" action="" method="post" enctype="text/plain">
  <input type="hidden" name="message" value="">
</form>
<form name="frmEmail" action="" method="post">
姓名:<input type="text" name="name" value="a"><BR>
電話:<input type="text" name="phone" value="b"><BR>
網(wǎng)址:<input type="text" name="website" value="c"><BR>
主題:<input type="text" name="subject" value="d"><BR>
內(nèi)容:<textarea name="message" >ee
ddd</textarea><BR>
<input type="button" name="send" value="send" onClick="toOutLook()">
</form>
</body>
</html>
點擊Send發(fā)送之后的內(nèi)容為

----------------------------------------
收件人: sundysea@hotmail.com
主題: d

message=姓名: a
電話: b
網(wǎng)址: c
主題: d
內(nèi)容: ee
ddd