Print preview not displaying as intended
Posted: Wed Dec 07, 2011 3:25 am
Using 1.10.2
Need to have a table on a page print exactly as it looks online with colours and borders.
CMSPrinting module - have added styling requirements to "Override print stylesheet". Do I need to do anything more with this or is it part of the Print css?
Page in question is "newcomp".
Override print stylesheet:
body.newcomp {font-family:arial; }
#main,
#table,
#table th,
#table th.col1,
#table th.col2,
#table th.col3,
#table th.col4,
#table th.col5,
#table td.col1,
#table td.col2,
#table td.col3,
#table td.col4,
#table td.col5,
{
display:block !important;
width:100% !important;
padding:1em !important;
}
#header,
#header h1,
#header h2,
#header img,
.nav,
#breadcrumbs,
div.hidden,
#search,
.cms_form,
#footer,
#news
{
display: none !important;
}
When I click on the print-friendly page icon it certainly shows only the table but there are no borders to the table or cells and I need them to make the page easier to read.
Then when I click on Print Preview in the browser, the page that comes up is the usual sort of printer page with no background colours and no grid for table unlike the page I see when I use the printer icon which at least has the colours correct but no borders.
I have {cms_module module='CMSPrinting' text="Print" showbutton="true"} on the page in question and the Print css attached to the main template for the site.
What am I doing wrong?
Page is a test page, active but not visible on line so will add screenshots.
Thanks
Need to have a table on a page print exactly as it looks online with colours and borders.
CMSPrinting module - have added styling requirements to "Override print stylesheet". Do I need to do anything more with this or is it part of the Print css?
Page in question is "newcomp".
Override print stylesheet:
body.newcomp {font-family:arial; }
#main,
#table,
#table th,
#table th.col1,
#table th.col2,
#table th.col3,
#table th.col4,
#table th.col5,
#table td.col1,
#table td.col2,
#table td.col3,
#table td.col4,
#table td.col5,
{
display:block !important;
width:100% !important;
padding:1em !important;
}
#header,
#header h1,
#header h2,
#header img,
.nav,
#breadcrumbs,
div.hidden,
#search,
.cms_form,
#footer,
#news
{
display: none !important;
}
When I click on the print-friendly page icon it certainly shows only the table but there are no borders to the table or cells and I need them to make the page easier to read.
Then when I click on Print Preview in the browser, the page that comes up is the usual sort of printer page with no background colours and no grid for table unlike the page I see when I use the printer icon which at least has the colours correct but no borders.
I have {cms_module module='CMSPrinting' text="Print" showbutton="true"} on the page in question and the Print css attached to the main template for the site.
What am I doing wrong?
Page is a test page, active but not visible on line so will add screenshots.
Thanks