CSS
#header, .icon-action, .post-footer, #comments h4, .postprint, .header, #sidebar-right-1, #sidebar-left-1, .sidebar, #footer-wrapper, #footer, .date-header, .post-meta-data, .comment-link, .comment-footer, #blog-pager, #backlinks-container, #navbar-section,#navbar-iframe, .subscribe_notice, .noprint {display: none;}
HTML
<span style='background: url(https://storage.ning.com/topology/rest/1.0/file/get/10907930669?profile=original) left no-repeat; padding-left: 42px; font-size:18px; font-weight:bold;'><a href='javascript:window.print()'> Print the post </a></span>
Replies
This code is not correct
This line refers to an external css style sheet and does not belong in your global css as it does nothing, using this you would use in html to point to a css file which has the style rules in it for printing and by just having this line in your css will be ignored.
<style media='print' type='text/css'>
The rest of the css you have just refers to elements on your web page and WILL affect your normal layout, for instance
.column-center-inner{width: 940px !important;}
The above line will simply set the column-center-inner of the page to 940px wide as it just a line of css outside of any printing rule and the same for all the other css above it and will make all the elements in that block of code not show because of the display none.
Also for the html all you have added is a <a> link tag called Print the post and will not do anything if clicked on.
You have either missed out posting the required code or this code above is incomplete.
Bizz
thanks a lot i changed the codes now they are perfectcss is still wrong though as it's still a global css style, normally you would either write an external style sheet for your print style or wrap your css style for printing in a media type css like this
@media print{
#header{ display:none }
}
for example
Bizz
try please! write the whole code working on my codes to make everything work perfectly for Ning plz