PHPackages                             tear/respect-validation-bundle - 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. tear/respect-validation-bundle

AbandonedSymfony-bundle[Validation &amp; Sanitization](/categories/validation)

tear/respect-validation-bundle
==============================

Integration of the respect/validation with Symfony2.1 or higher

0.1.0(12y ago)12.9kMITPHPPHP &gt;=5.3.3

Since Jul 23Pushed 12y ago2 watchersCompare

[ Source](https://github.com/leonnleite/Tear-RespectValidationBundle)[ Packagist](https://packagist.org/packages/tear/respect-validation-bundle)[ RSS](/packages/tear-respect-validation-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (1)Used By (0)

Tear\\RespectValidationBundle
=============================

[](#tearrespectvalidationbundle)

better integration between Symfony2 and "The most awesome validation engine ever created for PHP."

Installation
============

[](#installation)

\##Bring in the vendor libraries

Use Composer

```
// composer.json
"require": {
    "php": ">=5.3.2",
    // ...
    "tear/respect-validation-bundle": "dev-master",
    // ...
}

```

\##Add to your application kernel

```
// app/AppKernel.php
public function registerBundles()
{
    return array(
        // ...
        new Tear\Respect\ValidationBundle\TearRespectValidationBundle(),
        // ...
    );
}

```

---

Usage
=====

[](#usage)

### Use as service respect.validator:

[](#use-as-service-respectvalidator)

```
    //...
    class AcmeController extends Controller
    {
        public function indexAction()
        {
            $number = 123;
            $x = $this->get('respect.validator')->numeric()->validate($number);//true
    //...

```

### Use as Alias:

[](#use-as-alias)

```
