Download the PHP package v-technologies/transformist without Composer
On this page you can find all versions of the php package v-technologies/transformist. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download v-technologies/transformist
More information about v-technologies/transformist
Files in v-technologies/transformist
Package transformist
Short Description File conversion library
License
Homepage http://github.com/v-technologies/transformist
Informations about the package transformist
Transformist
Transformist is a PHP file conversion library. It provides a high level API to convert files into different formats painlessly.
It is also designed to be easily extended, just by adding custom converters.
Example
Here is what you could do to convert every word documents to PDF files in a directory:
You can use the setup( ) method in different ways to convert multiple documents in one pass:
Available conversions
Before going any further, you may want to know about the conversions that Transformist can handle. There's a method for that:
This method returns an array of all possible conversions. Each of its key represents an input type, and points to an array of output types.
Typically, it looks like this:
Here you can convert JPG images to PNG, and PNG images to TIFF.
Test
Transformist provides a way to check all converters for validity. Some could be runnable without further configuration, while others could rely on external librairies that must be installed for the converter to work.
$results now looks like this:
You should run this function only once when configuring your system or troubleshooting errors, as some converters could do some heavy computation to test their environment.