CakePHP TinyPNG Helper
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


A CakePhp Plugin that extends the HTML Image helper to resize and cache PNG files using the API.

#Requirements# *PHP 4,5
*CakePhp 2+
*TinyPNG API key


$ cd /your_app_path/Plugin
$ git submodule add TinyPng


  1. Create an account at
  2. Obtain your API key
  3. Create a copy of tinypng.php to /app/Config/tinypng.php
  4. Insert your API Key
  5. Edit your /app/Controller/AppController.php
class AppController extends Controller {
	public $helpers = array(
		'Html' => array('className' => 'TinyPng.TinyPng')

#Usage# This Plugin extends the Image helper, so usage is the same. There are no special calls required.

#Example# Load the CakePHP Favicon

<?php echo $this->Html->image('cake.icon.png'); ?>

#Change History# CakePHP TMDB v.1 - 2014-03-03
*Initial Committ