generate eml file
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> Send Email </TITLE>
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
</HEAD> <textarea id="textbox" style="width: 300px; height: 600px;">
To: sample <sample@hotmail.com>
Subject: Invoice
X-Unsent: 1
Content-Type: text/html <html>
<head>
<style>
body, html, table {
font-family: Calibri, Arial, sans-serif;
}
.pastdue { color: crimson; }
table {
border: 1px solid silver;
padding: 6px;
}
thead {
text-align: center;
font-size: 1.2em;
color: navy;
background-color: silver;
font-weight: bold;
}
tbody td {
text-align: center;
}
</style>
</head>
<body>
<table width=100%>
<tr>
<td><img src="http://192.168.255.221/logo.png" width="200" height="57" alt=""></td>
<td align="right"><h1><span class="pastdue"></span> INVOICE</h1></td>
</tr>
</table>
<table width=100%>
<thead>
<th>Invoice #</th>
<th>Days Overdue</th>
<th>Amount Owed</th>
</thead>
<tbody>
<tr>
<td>OU812</td>
<td>9</td>
<td>$4395.00</td>
</tr>
<tr>
<td>OU812</td>
<td>9</td>
<td>$4395.00</td>
</tr>
<tr>
<td>OU812</td>
<td>9</td>
<td>$4395.00</td>
</tr>
</tbody>
</table>
</body>
</html> </textarea>
<br> <button id="create">Create file</button><br><br>
<a download="invoice.eml" id="downloadlink" style="display: none">Download</a> <script>
(function () {
var textFile = null,
makeTextFile = function (text) {
var data = new Blob([text], {type: 'text/plain'});
if (textFile !== null) {
window.URL.revokeObjectURL(textFile);
}
textFile = window.URL.createObjectURL(data);
return textFile;
}; var create = document.getElementById('create'),
textbox = document.getElementById('textbox');
create.addEventListener('click', function () { var link = document.getElementById('downloadlink');
link.href = makeTextFile(textbox.value);
link.style.display = 'block'; }, false);
})();
</script>
</BODY>
</HTML>
generate eml file的更多相关文章
- Generate BKS File( Bouncy Castle KeyStore)
echo "Enter BKS output file name : \c" read filename echo "Enter BKS Password : \c&qu ...
- Generate input file for OVITO
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Tex ...
- How to generate a new dictionary file of mmseg
How to generate a new dictionary file of mmseg 0.Usage about mmseg-node memtioned in github : var mm ...
- User Word Automation Services and Open XML SDK to generate word files in SharePoint2010
SharePoint 2010 has established a new service called "Word Automation Services" to operate ...
- C#结合LumiSoft.Net.dll读取Outlook邮件(.eml格式邮件)
如果直接从Outlook(或者微软的其它邮件客户端如:Outlook Express.Windows Live Mail)的邮件文件(.eml格式)中提取各种电子邮件内容,使用LumiSoft.Net ...
- Freebie - Utility Form: Generate Excel Report From SQL Query In Oracle Forms 6i And 11g
Sharing a form to generate Excel file report from SQL query in Oracle Forms. This form can be used i ...
- python文件和文件夹訪问File and Directory Access
http://blog.csdn.net/pipisorry/article/details/47907589 os.path - Common pathname manipulations 都是和路 ...
- C# dmp debug, can't load pdb file
1. Project->Properties->Build->Advance, Debug Info : Full/pdb-only . set to [none] will no ...
- 5) mvn archetype:generate
获取帮助 mvn -h 命令格式 usage: mvn [options] [<goal(s)>] [<phase(s)>] -D,--define <arg> D ...
随机推荐
- java开发中的那些事(5)--------一点经历,败给2分钟的2个小时
特意记下这个经历,这个让我感慨万千又斗志昂扬的一次经历,这是经验,也是生活. 故事的始末是这种,先给大家上几句代码,如今身在家中,仅仅能凭记忆敲打几行,大致意思倒不会错: {field:'code', ...
- ITFriend创业败局(四):菜鸟CEO的自我修养
自创业自封CEO以来,短短3个月,又经历了无数的磨练,快速成长中. 创业不同于打工,他要求你必须有全局观和综合能力,技术.市场.商务,啥都得会,还要处理各种各样的问题和矛盾. 根据个人经历,我总结了以 ...
- [Django] Creating an app, models and database
To add a new app, first cd to the project. Then run: python manage.py startapp scrumboard After that ...
- js进阶 9-9 html控件如何实现回车键切换焦点
js进阶 9-9 html控件如何实现回车键切换焦点 一.总结 一句话总结:在onkeydown事件中判断event对象的键位码,然后focus事件. 二.js进阶 9-9 html控件如何实现回车键 ...
- erlang tcp发包速度测试
http://blog.sina.com.cn/s/blog_96b8a1540101317m.html 这段时间我们的项目遇到广播包的一些性能问题,想起之前看到yufeng老大提到的1s广播40K包 ...
- Procedural graphics architectures and techniques
BACKGROUND The evolution of graphics rendering technology has led to the development of procedural t ...
- 数据结构 Tricks(一)—— 父节点和左右孩子索引号之间的关系
如果以第 0 个位置开始标记树根节点,则第 i 个结点的左右孩子分别为: 2i+1 2i+2 反之,如果一个结点的标号为 i,则其父节点为: i/2:i 为左孩子结点: i/2-1:i 为右孩子结点: ...
- NOIP模拟 wall - 最大生成树
题目大意: 给出n个点,第i个点坐标是(\(x_i, y_i\)),给出m条边,第i条边的权值是\(w_i\),求将图变成一颗树所需要删除边的最小权值和. 题目分析: 首先要看出坐标其实是出题人使出的 ...
- MySQL执行计划分析
原文:MySQL执行计划分析 一. 执行计划能告诉我们什么? SQL如何使用索引 联接查询的执行顺序 查询扫描的数据函数 二. 执行计划中的内容 SQL执行计划的输出可能为多行,每一行代表对一个数据库 ...
- react持续记录零散笔记
根据 React 的设计,所有的 DOM 变动,都先在虚拟 DOM 上发生,然后再将实际发生变动的部分,反映在真实 DOM上,这种算法叫做 DOM diff 这些生命周期在深入项目开发阶段是非常重要的 ...