PHPackages                             josegonzalez/cakephp-purifiable - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Validation &amp; Sanitization](/categories/validation)
4. /
5. josegonzalez/cakephp-purifiable

AbandonedArchivedCakephp-plugin[Validation &amp; Sanitization](/categories/validation)

josegonzalez/cakephp-purifiable
===============================

CakePHP plugin to makes your model data so fresh, so clean

3716.1k8PHP

Since Nov 29Pushed 10y ago1 watchersCompare

[ Source](https://github.com/josegonzalez/cakephp-purifiable)[ Packagist](https://packagist.org/packages/josegonzalez/cakephp-purifiable)[ RSS](/packages/josegonzalez-cakephp-purifiable/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

[![Build Status](https://camo.githubusercontent.com/43719e84cdd2af6bf4a45fac908d4bc05290df8377e71b59a3c99b36abba932c/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6a6f7365676f6e7a616c657a2f63616b657068702d70757269666961626c652f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/josegonzalez/cakephp-purifiable)[![Coverage Status](https://camo.githubusercontent.com/0e5546aeea376ffccdf060858ec49fe562bd2c91aefadd931829849ff36c94e5/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c732f6a6f7365676f6e7a616c657a2f63616b657068702d70757269666961626c652e7376673f7374796c653d666c61742d737175617265)](https://coveralls.io/r/josegonzalez/cakephp-purifiable?branch=master)[![Total Downloads](https://camo.githubusercontent.com/aa0b4e695b60144e7fcf68265ec188113879633d5fe1ce7badf37d28dcd79805/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6a6f7365676f6e7a616c657a2f63616b657068702d70757269666961626c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/josegonzalez/cakephp-purifiable)[![Latest Stable Version](https://camo.githubusercontent.com/d8d06518bfde0a56cb9f3b56cb3a2cb6909e84dd0b1f3b6378cb0073085e7cd4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6a6f7365676f6e7a616c657a2f63616b657068702d70757269666961626c652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/josegonzalez/cakephp-purifiable)[![Documentation Status](https://camo.githubusercontent.com/8a8cac1bed93f18a5cbecc449fb5d829b9801debd53ccb43cf4d2c87fada89f7/68747470733a2f2f72656164746865646f63732e6f72672f70726f6a656374732f63616b657068702d70757269666961626c652f62616467652f3f76657273696f6e3d6c6174657374267374796c653d666c61742d737175617265)](https://readthedocs.org/projects/cakephp-purifiable/?badge=latest)[![Gratipay](https://camo.githubusercontent.com/40a48c7b3fc02e9d39dd715fe09e404c4cb2e89288c6ace0773d2aab6913b46f/68747470733a2f2f696d672e736869656c64732e696f2f67726174697061792f6a6f7365676f6e7a616c657a2e7376673f7374796c653d666c61742d737175617265)](https://gratipay.com/~josegonzalez/)

Purifiable
==========

[](#purifiable)

Sanitize model data easily

Background
----------

[](#background)

Someone on #cakephp had an issue with PHP timing out. Normally, I’d say it was just bad coding, but it’s probably just a bad practice on their part. The issue they had is with HTML Purifier. I built this behavior to make sanitizing data a bit simpler.

Requirements
------------

[](#requirements)

- CakePHP 2.x
- PHP 5.3

Installation
------------

[](#installation)

*\[Using [Composer](http://getcomposer.org/)\]*

Add the plugin to your project's `composer.json` - something like this:

```
	{
		"require": {
			"josegonzalez/cakephp-purifiable": "dev-master"
		}
	}

```

Because this plugin has the type `cakephp-plugin` set in its own `composer.json`, Composer will install it inside your `/Plugins` directory, rather than in the usual vendors file. It is recommended that you add `/Plugins/Purifiable` to your .gitignore file. (Why? [read this](http://getcomposer.org/doc/faqs/should-i-commit-the-dependencies-in-my-vendor-directory.md).)

*\[Manual\]*

- Download this:
- Unzip that download.
- Copy the resulting folder to `app/Plugin`
- Rename the folder you just copied to `Purifiable`

*\[GIT Submodule\]*

In your app directory type:

```
	git submodule add -b master git://github.com/josegonzalez/cakephp-purifiable.git Plugin/Purifiable
	git submodule init
	git submodule update
```

*\[GIT Clone\]*

In your `Plugin` directory type:

```
	git clone -b master git://github.com/josegonzalez/cakephp-purifiable.git Purifiable

```

### Enable plugin

[](#enable-plugin)

In 2.0 you need to enable the plugin in your `app/Config/bootstrap.php` file:

```
	CakePlugin::load('Purifiable');

```

If you are already using `CakePlugin::loadAll();`, then this is not necessary.

Usage
-----

[](#usage)

TODO
----

[](#todo)

License
-------

[](#license)

The MIT License (MIT)

Copyright (c) 2010 Jose Diaz-Gonzalez

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

29

—

LowBetter than 60% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity32

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 77.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/f38b500117ee9754ea7a4c56b800c8151ca0605b1715a3b2ff054aae504f7393?d=identicon)[josegonzalez](/maintainers/josegonzalez)

---

Top Contributors

[![josegonzalez](https://avatars.githubusercontent.com/u/65675?v=4)](https://github.com/josegonzalez "josegonzalez (27 commits)")[![JustAWebDev](https://avatars.githubusercontent.com/u/7663162?v=4)](https://github.com/JustAWebDev "JustAWebDev (7 commits)")[![bmpolyak](https://avatars.githubusercontent.com/u/179392?v=4)](https://github.com/bmpolyak "bmpolyak (1 commits)")

### Embed Badge

![Health badge](/badges/josegonzalez-cakephp-purifiable/health.svg)

```
[![Health](https://phpackages.com/badges/josegonzalez-cakephp-purifiable/health.svg)](https://phpackages.com/packages/josegonzalez-cakephp-purifiable)
```

###  Alternatives

[webmozart/assert

Assertions to validate method input/output with nice error messages.

7.6k894.0M1.2k](/packages/webmozart-assert)[bensampo/laravel-enum

Simple, extensible and powerful enumeration implementation for Laravel.

2.0k15.9M104](/packages/bensampo-laravel-enum)[nette/forms

📝 Nette Forms: generating, validating and processing secure forms in PHP. Handy API, fully customizable, server &amp; client side validation and mature design.

54013.2M446](/packages/nette-forms)[swaggest/json-schema

High definition PHP structures with JSON-schema based validation

48612.5M73](/packages/swaggest-json-schema)[stevebauman/purify

An HTML Purifier / Sanitizer for Laravel

5325.6M19](/packages/stevebauman-purify)[ashallendesign/laravel-config-validator

A package for validating your Laravel app's config.

217905.3k5](/packages/ashallendesign-laravel-config-validator)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
