PHP code example of willmorgan / silverstripe-cropperfield
1. Go to this page and download the library: Download willmorgan/silverstripe-cropperfield 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/ */
willmorgan / silverstripe-cropperfield example snippets
$has_one = array(
'MyBigPhoto' => 'Image',
'MyArtDirectionCrop' => 'Image',
);
$uploadField = new UploadField('MyBigPhoto', 'Big Photo Uploader');
$cropperField = new CropperField\CropperField(
'MyArtDirectionCrop',
'Cropped Image',
new CropperField\Adapter\UploadField(
$uploadField
)
);