PHP code example of ppito / contentful-html-to-rich-text

1. Go to this page and download the library: Download ppito/contentful-html-to-rich-text 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/ */

    

ppito / contentful-html-to-rich-text example snippets



// composer  '/vendor/autoload.php';


$content = \Contentful\HtmlToRichText\Tool::parse("<p>Hello</p><p>Another with <strong>bold maybe?</strong></p>");