PHP code example of sageit / markupengine

1. Go to this page and download the library: Download sageit/markupengine 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/ */

    

sageit / markupengine example snippets




 new MarkupEngine([]
    'parse_on_shutdown' 	=> true,
    'tag_directory' 		=> __DIR__.DIRECTORY_SEPARATOR.'tags'.DIRECTORY_SEPARATOR,
    'sniff_for_buried_tags' => true
]);


namespace MarkupEngine;

class Youtube extends CustomMarkup{

	public function render(){
		return <<< HTML
			<iframe width="560" height="315" 
				src="https://www.youtube.com/embed/{$this->src}" 
				frameborder="0" 
				allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" 
				allowfullscreen>
			</iframe>

HTML;
		}
	}