Skip to content
SilverStripe Module. Replaces SilverStripe's inbuilt asset management with Cloudinary.
Branch: master
Clone or download
oilee80 Merge pull request #41 from MadeHQ/feature/add-extend-for-file-form-f…

Add extend on `MadeHQ\Cloudinary\Forms\FileFormFactory::getFormFieldT…
Latest commit 4380ec7 May 1, 2019

Silverstripe Cloudinary Module

This module provides fields & DataObjects for managing files, audio & images that are stored in Cloudinary.


composer require mademedia/silverstripe-cloudinary




putenv('CLOUDINARY_URL=cloudinary://<API Key>:<API Secret>@<Cloud name>');

Add DataObjects


use MadeHQ\Cloudinary\Model\FileLink;
use MadeHQ\Cloudinary\Model\ImageLink;

private static $has_one = [
    '<FileVariableName>' => FileLink::class,
    '<ImageVariableName>' => ImageLink::class,

Add CMSFields


use MadeHQ\Cloudinary\Forms\UploadImageField;
use MadeHQ\Cloudinary\Forms\UploadFileField;

public function getCMSFields()
    $fields = parent::getCMSFields();
    return $fields;

Output in template


Adding files to SilverStripe templates

<%-- File URL --%>

<%-- File Title --%>


Adding images to SilverStripe templates

<%-- Original Image URL --%>

<%-- Original Image Credit --%>

<%-- Original Image Caption --%>

<%-- Original Image Gravity --%>

<%-- Original Image at a specific size fill will default to "fill" --%>
$ImageVariableName.URL(100, 200)

<%-- Original Image at a specific size with a specific format --%>
$ImageVariableName.URL(100, 200, 'fill', 'png')


JS Amends are done in client\src\js and client\src\styles

After changes you can run yarn build or during development use yarn watch

Also required for development is yarn

You can’t perform that action at this time.