PHP: How to export HTML to DOC

When developing online projects, it is often necessary to save the HTML page as a document that can be used separately, for example, sent by e-mail, viewed and edited offline. A convenient way is to export the HTML page to one of the most commonly used text formats – doc.

The free open-source PHP-module “html_to_doc” can be used to export the HTML page to the DOC document. It can convert the HTML to the DOC document, which will be correctly processed by the text editor MS Word. If the HTML page includes images, they will be embedded in the DOC document.

The PHP module can be downloaded from

PHP: How to get the full class name with static inheritance

PHP supports the Late Static Bindings mechanism. The full class name with static inheritance we can get by calling the function:



How to check code execution time in PHP

To check how match time code execution takes you need to frame checking code with following instructions:

This example result:

Executed for: 8.9997079372406 sek.