PHP code example of netwerkstatt / silverstripe-image-toolkit
1. Go to this page and download the library: Download netwerkstatt/silverstripe-image-toolkit 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/ */
netwerkstatt / silverstripe-image-toolkit example snippets
use SilverStripe\Core\Extension;
class MyImageExtension extends Extension
{
public function updateWatermarkLogo(&$logo)
{
$siteConfig = \SilverStripe\SiteConfig\SiteConfig::current_site_config();
if ($siteConfig->WatermarkLogoID) {
$logo = $siteConfig->WatermarkLogo();
}
}
}