I'm working with TCPDF to convert some HTMLto PDF. I can't put padding into my table, I have some borders and the text collapse with those borders, I've read that TCPDF doesn't allow some CSS.
Also I can't change the height of the table, so I'm working with cellpadding="-1"
There's my pdf.


in the middle I have cellpadding="0";
So... How can I set height to a <tr> or someone have some magic trick with TCPDF for a padding or margin?
`
<table border="0" align="center" cellpadding="-2" cellspacing="0">
<tr>
<td width="50%" class="marcoNegro" ><p align="center" style="font-size:8px;">
<font size="7"><strong>Contratante</strong></font><br>
Inversiones Accionarias Landus S. A. de C. V.</p></td>
<td width="1%"> </td>
<td width="23%" class="marcoNegro"><p align="center" style="font-size:8px;"><font size="7"><strong>Núm. de certificado</strong></font><br>
<?php echo $rowLg->id_tabla;?></p></td>
<td width="1%"> </td>
<td width="23%" class="marcoNegro"><p align="center" style="font-size:8px;"><font size="7"><strong>Número de póliza</strong></font><br>
935492</p></td>
</tr>
</table>`
You need to use cellpadding. You need to build a more complex in structure which allows you to use cellpading on desired cells.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With