transform - rotate and scale is not working when i convert html content to pdf

Shail Paras picture Shail Paras · Apr 2, 2013 · Viewed 9.6k times · Source

I am using html2pdf to convert html content with images to pdf and i have also added an option to rotate and flip the images... Right now pdf is created successfully ... but if i have rotated or flipped any image by using css transform:rotate(90deg);

transform:scaleX(-1);

then in pdf file that images is not looking rotated or flipped... Any idea to get rid of this issue... Please share ...or any solution for that.

Thanks in Advance.

Answer

Guangyu Wu picture Guangyu Wu · Jul 19, 2017

use "-webkit-transform" instead of "transform". for example:

 -webkit-transform: rotate(90deg);