Yii v2 snippet guide II

Comparing #29 with #30

Revision #30 was created by rackycz rackycz on Oct 2, 2020, 10:22:26 AM.

TCPDF

Content

[...]
```php
$pdf->writeHTML($html);
```

**Note:** When printing pageNr and totalPageCount to the footer, writeHTML() was not able to correctly interpret methods getAliasNumPage() and getAliasNbPages() as shown in [Example 3](https://tcpdf.org/examples/example_003/). I had to use rendering  method Text() and position the numbers correctly like this:
 
 
```php
 
$this->writeHTML($footerHtmlTable);
 
$this->SetTextColor('128'); // I have gray pageNr
 
$this->Text(185, 279, 'Page ' . $this->getAliasNumPage() . '/' . $this->getAliasNbPages());
 
$this->SetTextColor('0'); // returning black color
 
```
 



**New version of TCPDF**

... to be finished ...
[...]