Download Print.css in a .zip file
Not knowing CSS very well and being new to WordPress, I looked all over for a Printer Friendly plugin that would print just the body of the pages in a post or a page on my website. I found a plugin, but I could not get it to work. (I am not experienced enough to know how to edit CSS and PHP very well) . I also found a couple of pre-made CSS files that were to make the posts and pages printer-friendly, but I did not have the right theme or know what they were trying to include, and so it would not print right for me.
In the end, I was able to find a basic CSS tutorial on how to make a printer-friendly CSS file. But, the tutorial was not really made for WordPress. So, back to the drawing board. In the end, I created a printer-friendly CSS file. I had to add a bit of code to the header.php page of the theme to get it to work correctly. This file will not give you an on screen printer preview of what it will print. But, if you goto File / Print Preview in the browser, it will show you what the page will look like before you print it.
This one file may not work for all, but I have included a short how-to to modify it. Basically, if it is showing things you do not want to print, then look in your theme / style.css (For WordPress) file to see what the name of the ID is. For example, if it is showing the menu blocks on the right and left side of the page, and you do not want to print those, then look in the style.css file and find what they are called. For example, you might find this in your style.css:
#block {
padding: 0 0 0 0;
font-size: 80%;
text-align: justify;
}
So, in the print.css , replace
#right_block {
display: none;
}
with
#block {
display: none;
}
and it will make it so what is defined in the style.css as #block will not display when you print it. You can use this to narrow down the elements on the page you want to be printed.
Also, for WordPress, you need to add the following to your header.php file that is found in your theme folder.
<link rel=”stylesheet” type=”text/css” media=”print” href=”<?php echo get_settings(’siteurl’); ?>/print.css” />
If you are not using WordPress, you still need to put this in the head of the page(s) you want to be printer friendly.
To view it before it prints, open your browser, see if it has File | Printer Preview and click on it, view it and then you can print it.
Unfortunately, my knowledge on CSS and PHP is extremely limited so I will not be able to support this. The best thing I can say is play around with it and try new things. You can always delete the print.css if you get it all out of whack. It might take a few tries to get it just right for what you want to print.
![]()







October 23rd, 2005 at 9:26 pm
Thank you for writing this post and for the help on the WP forums! I’m looking forward to working with print.css.
Best wishes!
October 23rd, 2005 at 10:31 pm
You are welcome. I hope it helps!
December 27th, 2005 at 8:51 am
Very useful, thanks.
January 25th, 2006 at 9:55 am
Alles, das Sie wnschen, ist vor Ihnen recht. Die Frage ist “was Sie tun mit ihm”?
January 27th, 2006 at 1:13 pm
Great blog. Found your blog while searching for more information at yahoo about this post . Your blog has quite a lot of interesting thoughts. Keep up the good work!
January 27th, 2006 at 6:46 pm
You have really done a good job on this. Keep it up!
February 2nd, 2006 at 1:25 am
Hi, I like your site! I enjoyed browsing it. Thanks. In Dutch we say dank-je-wel 4 thanks))
February 2nd, 2006 at 9:01 pm
I like what you did with the design of your blog! Compliments. Regards, Albert.
February 4th, 2006 at 1:11 am
Stopping by! I am trying to start my own blog on disaster recovery site suggest.I heard some people just have blogs now and don’t use regular urls? Do you agree with this way to promote url?. Just starting out, DREW
February 7th, 2006 at 12:12 pm
I loved your post! I came across your blog and it really cuaght my attention, I’ll be sure to come back for more! Keep up the good work!
February 13th, 2006 at 2:15 am
Hi, My name is Suzanne from France. 16 years of age. I like this too! I am a student, doing research on the recent ‘bloghype’ I hope you do not mind me using it coming thursday when I have to finish my project. It would be nice to show my teachers I learned something here. Thanks.
February 13th, 2006 at 1:03 pm
Hi, I thought I’d just leave this message on your blog. I hope you don’t mind. I’ve been trying to find blogs where people are talking about Search engine marketing tutorials and when I was looking, I found this one on this post. You have helped me in some way. Anyway, I want to say thank you before I go off to find some more info about it.
February 14th, 2006 at 8:52 pm
I couldn’t agree more!
February 15th, 2006 at 3:00 pm
I really could care less but I did agree with what you said.
February 15th, 2006 at 6:05 pm
Thanks for the information. Very helpful.
February 16th, 2006 at 3:04 am
Awesome! Thanks.
February 17th, 2006 at 11:43 am
Awesome! Thanks.
February 18th, 2006 at 12:50 am
Wow this is a nice site. :0) I like the comments even though I don’t 100% agree with all of them. I am a grad student at the University of Sacred Heart in Connecticut. If you don’t mind I will use your blog as a example for my semester project that I am doing on the internet and ecommerce. If you reject the thought send me a quick email
-Corey
February 18th, 2006 at 4:49 pm
What is up! I am trying to start my own blog on restore data excel.Can you add your blog as a subdirectory of your domain if you already paid for domain?. Thank you so much, LEONARDO
November 12th, 2008 at 3:02 pm
I use something called Programmers Notepad which is completely free to edit my css files.
November 14th, 2008 at 1:37 am
Thank you for writing this post!
November 14th, 2008 at 11:35 pm
Great post girl!