Forum Moderators: not2easy
I'm a bit confused as to where the problem lies. Do you mean that there is a problem with setting print style for the HTML page, or that there is a problem in the conversion to the PDF - which then is not 'print ready'?
It reads to me as if you are working on the former, though I would think that one print ready option or the other would be sufficient.
If the former (print style sheet), the quickest shot for a hack would be to try and use something like {position: absolute; bottom: 0;}. Would have to see enough code to recreate the correctly presented HTML/CSS and the broken print preview to suggest further. (Have to watch that the print style sheet stands up cross-browser too.)
The footer at present is like this
<div id="footer">
<table>
<tr>
<td colspan='4' style='text-align: center;'>
Title to the above goods does not pass to the purchaser until this invoice is settled in full including VAT.<br />
Terms and Conditions are available upon request.
</td>
</tr>
<tr>
<td width='30%'><img src='http://www.example.com/footer_logo.jpg'></td>
<td width='40%'>CompanyName is a Registered Trademark</td>
<td width='10%'>Partners</td>
<td width='20%'>Mr #*$! (Managing)<br />
x #*$!<br />
VAT No. #*$! #*$!x xx</td>
</tr>
</table>
<?php if ($this->settings_model->get_setting('display_branding') == 'y'):?>
<p>
<?php echo $this->lang->line('invoice_generated_by');?>
<?php echo $this->lang->line('example_logo');?><br />
<a href="http://www.example.org/">http://www.example.org</a>
</p>
<?php endif;?>
</div>
The only CSS I have in the page at present is:
body {
margin: 0.5in;
}
h1, h2, h3, h4, h5, h6, li, blockquote, p, th, td {
font-family: Helvetica, Arial, Verdana, sans-serif; /*Trebuchet MS,*/
}
h1, h2, h3, h4 {
color: #5E88B6;
font-weight: normal;
}
h4, h5, h6 {
color: #5E88B6;
}
h2 {
margin: 0 auto auto auto;
font-size: x-large;
}
h2 span {
text-transform: uppercase;
}
li, blockquote, p, th, td {
font-size: 80%;
}
ul {
list-style: url(img/bullet.gif) none;
}
table {
width: 100%;
}
td p {
font-size: small;
margin: 0;
}
th {
color: #FFF;
text-align: left;
background-color:#000000;
}
.example_invoice_bam {
color: #5E88B6;
font-weight: bold;
text-transform: capitalize;
}
.example_invoice_inv {
font-weight: bold;
font-variant: small-caps;
color: #333;
}
#footer {
border-top: 1px solid #CCC;
//text-align: right;
font-size: small;
color: #999999;
position: relative;
margin-top: -150px; /* negative value of footer height */
height: 150px;
clear:both;
}
#footer a, td {
color: #999999;
text-decoration: none;
font-size: x-small;
}
#totals {
text-align: right;
}
table.stripe {
border-collapse: collapse;
page-break-after: auto;
}
table.stripe td {
border-bottom: 1pt solid black;
}
[edited by: swa66 at 8:12 am (utc) on Sep. 21, 2009]
[edit reason] specifics, use example.com, it can never be owned [/edit]