PHP code example of endroid / tile

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

    

endroid / tile example snippets


use Endroid\Tile\Tile;

$tile = new Tile();
$this->setBackground(Tile::BACKGROUND_C);
$tile->setText("Life is too short to be generating tiles");
$tile->setSize(300);
$tile->render();


// app/AppKernel.php

public function registerBundles()
{
    $bundles = [
        // ...
        new Endroid\Tile\Bundle\TileBundle\EndroidTileBundle(),
    ];
}