Skip to content

Latest commit

 

History

History
19 lines (13 loc) · 534 Bytes

README.md

File metadata and controls

19 lines (13 loc) · 534 Bytes

Getting Started

composer require assetplan/imgproxy

Building the URL

<?php

$key = '0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef';
$salt = '0123456789abcdef0123456789abcdef';

$builder = new Assetplan\Imgproxy\UrlBuilder('https://imgproxy.example.com', $key, $salt);

$url = $builder->setImageUrl('https://example.com/image.jpg')->insecure()->resize(100, 100, ResizingType::Fill)->getUrl();

// https://imgproxy.example.com/insecure/rs:fill:100:100/plain/https://example.com/image.jpg