谷歌浏览器的打印功能

var OpenWindow = window.open("");  
		    OpenWindow.document.write("<HTML>"); 
		    OpenWindow.document.write("<HEAD>"); 
		    OpenWindow.document.write("<meta http-equiv=\"Content-Type\" content=\"text\/html; charset=utf-8\" \/>"); 
		    OpenWindow.document.write("<TITLE><\/TITLE>"); 
		    OpenWindow.document.write("<\/HEAD>"); 
		    OpenWindow.document.write(html); 
		    OpenWindow.document.write(); 
		    OpenWindow.document.write("<\/BODY>"); 
		    OpenWindow.document.write("<\/HTML>"); 
		    OpenWindow.print();

html 拼本身的页面代码就好了javascript

相关文章
相关标签/搜索