Friday, April 08, 2005

Solved printing problem with blogs.

TwitThis

I have solved the printing problem with Blogger blogs that Walt Crawford mentioned in his last issue of Cites & Insights. It might also work for other blogs where the content moves to the right as it prints and eventually disappears. What is required is two different styles, one for printing and one for screen.

Below is the style I use for printing.
Note the media="print" portion.
For screen display just add media="screen" to your normal style in the template.

I added the separate style for print. It works very well.
<style type="text/css" media="print">

body {
background: white;
font-size: 12pt;
font-family:Palatino,'Times New Roman',times,serif;
}
#sidebar { display: none; }

#content {
width: auto;
margin: 0 5%;
padding: 0;
border: 0;
float: none !important;
color: black;
background: transparent;
}

a:link, a:visited {
background: transparent;
font-weight: bold;
text-decoration: underline;
}

#b-navbar {
visibility: hidden;
}

/*]]>*/</style>

1 comments:

bevinchu@gmail.com said...

Dear BBL,

I thought I was going crazy. I Googled all over the place but couldn't find anyone who was talking about this problem. It was as if I was the only Firefox user on earth who ever tried to print a Blogger webpage! I'm glad someone else has at least acknowledged that the problem is real, that it actually exists, that I'm not going out of my mind. But what are Firefox and Blogger doing about it? Why don't they fix it? I really don't get it.

Post a Comment

Inappropriate Comments will not be approved for display and will be deleted.

Copyright

Creative Commons License
This work is licensed under a Creative Commons License.