HOWTO: Stop using the print link! CSS fix to print a page without the menu!
Posted: Fri Dec 09, 2005 12:32 am
Don't like having to click a link to reload the page without the left-hand menu to be able to print? Follow the simple steps below to end the need to do that. This uses CSS media types to set the width of the menu (div.leftsidebar) to 0px when printing! Let me know if there are any bugs or omissions here so I can fix it. I set my site up to do this a long time ago, so I may have forgotten something...
-Create a new Stylesheet in admin and give it a media type of "print" without the quotes
-Then copy your default CSS from your template into the new StyleSheet
-Edit the new Stylesheet in the following ways
-set width = 0px; in div.leftsidebar
-set padding = 0px; in div.leftsidebar
-attach the new Stylesheet to your template
-Reload your page and from now on you can print your pages directly!
(Note: Unfortunately, in my tests, IE does not support media types and this does not work for those printing from that rather broken browser.)
-Create a new Stylesheet in admin and give it a media type of "print" without the quotes
-Then copy your default CSS from your template into the new StyleSheet
-Edit the new Stylesheet in the following ways
-set width = 0px; in div.leftsidebar
-set padding = 0px; in div.leftsidebar
-attach the new Stylesheet to your template
-Reload your page and from now on you can print your pages directly!
(Note: Unfortunately, in my tests, IE does not support media types and this does not work for those printing from that rather broken browser.)