There are 2 ways you can use BuildVu from PHP. The first is using the command line, via
exec(). The second option is hosting BuildVu on an application server and running it as a web service you can interact with via a REST API.
Option 1: Running BuildVu from PHP via the command line
This option requires Java to be installed.
The following code will start a new command-line process in the background, run the specified command and then store any output in the $output array.
$output = ;
exec('java -Xmx1024M -jar /path/to/buildvu.jar /path/to/input.pdf /path/to/output/dir/', $output);
Conversion settings are controlled by passing in system properties with the command. You can find more information here.
Option 2: Running BuildVu from PHP via an application server
Once you deploy BuildVu on an application server, here is how to use our PHP wrapper for the REST API.
Note: Knowledge of Composer is required for usage of the library.
composer require idrsolutions/idrsolutions-php-client