That's because you haven't assigned the other two divs in question the appropriate IDs
A complete example would be:
Code:
<style type="text/css">
@media print{
body{ background-color:#FFFFFF; background-image:none; color:#000000 }
#ad{ display:none;}
#leftbar{ display:none;}
#contentarea{ width:100%;}
}
</style>
<body>
<div id="ad">banner here</div>
<div id="leftbar">Left bar here</div>
<div id="contentarea">Content here</div>
</body>
In the above example, only the Content Area will be printed out.
I highly urge you to read the tutorial I cited. It seems you're just taking the code I posted as is without understanding how CSS works, which makes it impossible for you to adopt the code to your page set up.
Bookmarks