PHP code example of litlife / book-converter

1. Go to this page and download the library: Download litlife/book-converter library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

litlife / book-converter example snippets

bash
use Litlife\BookConverter\BookConverter;

$outputFile = (new BookConverter())
  ->with('calibre')
  ->open(__DIR__ . '/files/test.txt')
  ->convertToFormat('fb2');
  
print_r($outputFile->getFilePath());  
print_r($outputFile->getExtension());
print_r($outputFile->getStream());