Created
September 3, 2015 19:24
-
-
Save benglass/0c55514b67e96b9bcb5e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$loader = require_once __DIR__.'/app/bootstrap.php.cache'; | |
require_once __DIR__.'/app/AppKernel.php'; | |
$kernel = new AppKernel('dev', true); | |
$kernel->loadClassCache(); | |
$kernel->boot(); | |
$container = $kernel->getContainer(); | |
$validator = $container->get('validator'); | |
$url = 'http://www.rilin.state.ri.us/representatives/Messier'; | |
$result = $validator->validate($url, new \Symfony\Component\Validator\Constraints\Url()); | |
var_dump($result); // No violations |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment