Forum


Replies: 2   Views: 2451
Image sized at 127 dpi?
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by cmoller  · 26-03-2019 - 20:52

We are generating Word documents from HTML using embedHTML and the images are being sized smaller than expected. For example, for an image that is 99 x 75px at 72 dpi the image size in the generated document the image size is 1.98cm x 1.5cm. If we specify the size of the image as 78 x 60px via the img height & width attributes the image size in the generated document is 1.56 cm x 1.2 cm. It looks like the images are being sized as 127 dpi. Is that the case? And why would that be if the image itself is 72 dpi? If we can rely on images always being sized at 127 dpi we can scale them up manually before passing to embedHTML but we don't want to make that assumption if something different is happening.