new Date().toJSON().slice(0,10)
More
//print html
<div id="printme">
...
</div>
function printIt(printThis) {
var win=null;
win = window.open('','offprint','width=810px height=882px');
self.focus();
win.document.open();
win.document.write('<'+'!DOCTYPE html'+' PUBLIC '+'-//W3C//DTD XHTML 1.0 Transitional//EN '+'http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd >');
win.document.write("<html xmlns='http://www.w3.org/1999/xhtml'><head>");
win.document.write("<meta http-equiv='X-UA-Compatible' content='IE=edge' />");
win.document.write("<meta http-equiv='Content-Type' content='text/html; charset=utf-8' />");
win.document.write('<link rel=stylesheet type="text/css" href="/css/admin/reset.css" />');
win.document.write('<link href="/css/admin/jquery-ui-1.8.21.custom.css" rel="stylesheet" />');
win.document.write('<link rel="stylesheet" type="text/css" href="/css/admin/common.css" />');
win.document.write('<link rel="stylesheet" type="text/css" href="/css/admin/contents.css" /> ');
win.document.write('<scr' + 'ipt language="javascript" type="text/javascript" src="/js/admin/jquery-1.8.1.min.js"></scr' + 'ipt>');
win.document.write('<scr' + 'ipt language="javascript" type="text/javascript" src="/js/admin/jquery-ui-1.8.21.custom.min.js"></scr' + 'ipt>');
win.document.write('<scr' + 'ipt language="javascript" type="text/javascript" src="/js/admin/layout.js"></scr' + 'ipt>');
win.document.write("</head><body>");
win.document.write('<div id="wrap1">');
win.document.write('<div id="container">');
win.document.write('<div class="content">');
win.document.write('<div class="pg_navi">');
win.document.write('</div>');
win.document.write(printThis);
win.document.write('</div>');
win.document.write("</body></html>");
win.document.close();
win.focus();
win.print();
}
댓글 없음:
댓글 쓰기