Home > JavaScript > JavaScript – Print

JavaScript – Print

IE using activex control, printing header/footer avoid

<script language=”Javascript”>
function readyprint() {   factory.printing.header = “”;   factory.printing.footer = “”; }

<body onLoad=”readyprint()”>
<object id=factory style=”display:none”
classid=”clsid:1663ed61-23eb-11d2-b92f-008048fdd814″ viewastext codebase=”smsx.cab#Version=5,0,4,185″>

Hello world ~ click print preview in IE and it will works
– download the cab file from : google it for smsx.cab.


For all other browsers how to do that?

First of all it doesnt work, still in research.!!

<title>Thisisthe Filename</title>

<style type=”text/css” media=”print, screen” >

@media print {

@page  { /*  here other  */}

body { font-size: 40px; /*  it will increase while print preview but not in web  view */







Categories: JavaScript
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: