|
Печать документа с помощью JavaScript
|
|||
---|---|---|---|
#18+
При распечатке Aspx-страницы используется следующий скрипт, но есть одна проблема - на странице справа вверху отображается "Page 1 of 2", а внизу страницы - ее адрес. Как сделать так чтобы этих лишних записей не было? function printReport() { showModalDialog( location.href+(location.href.indexOf("?")<0?"?":"&")+"print=true", null, "help:no;resizable:no;status:no;dialogHeight:100px;dialogWidth:200px;"); } function doPrint() { document.all["buttons"].style.display="none"; document.all["Form1"].style.display=""; document.all["printLink"].outerHTML=""; document.body.style.backgroundColor="#ffffff"; print(); window.close(); } function window.onload() { preLoad(); if(document.all["btnPrint"]) { document.all["btnPrint"].disabled=false; setTimeout("btnPrint_focus()",200); } } function preLoad() {} function btnPrint_focus() { var e; try { document.all["btnPrint"].focus(); } catch(e){} } ... |
|||
:
Нравится:
Не нравится:
|
|||
27.09.2006, 12:38 |
|
Печать документа с помощью JavaScript
|
|||
---|---|---|---|
#18+
Никак. Колонтитулы - в настройках броузера. ... |
|||
:
Нравится:
Не нравится:
|
|||
27.09.2006, 13:42 |
|
|
start [/forum/topic.php?fid=22&msg=34015395&tid=1459309]: |
0ms |
get settings: |
11ms |
get forum list: |
14ms |
check forum access: |
4ms |
check topic access: |
4ms |
track hit: |
38ms |
get topic data: |
11ms |
get forum data: |
3ms |
get page messages: |
46ms |
get tp. blocked users: |
2ms |
others: | 269ms |
total: | 402ms |
0 / 0 |