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 | |
$connectionParams = array( | |
"dbname" => "CHANGEME", | |
"user" => "CHANGEME", | |
"password" => "CHANGEME", | |
"host" => "localhost", | |
"driver" => "pdo_mysql" | |
); |
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 | |
public function someAction() | |
{ | |
$response = $this->get("response"); | |
$response->setContent("This is some text."); | |
return $response; | |
} |
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 | |
public function someAction() | |
{ | |
$this->getResponse()->setContent("This is some text."); | |
return sfView::NONE; | |
} |
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
services: | |
login_listener: | |
class: 'Acme\UserBundle\Listener\LoginListener' | |
arguments: ['@security.context', '@doctrine'] | |
tags: | |
- { name: 'kernel.event_listener', event: 'security.interactive_login' } |
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 | |
namespace Acme\UserBundle\Listener; | |
use Symfony\Component\Security\Http\Event\InteractiveLoginEvent; | |
use Symfony\Component\Security\Core\SecurityContext; | |
use Doctrine\Bundle\DoctrineBundle\Registry as Doctrine; // for Symfony 2.1.0+ | |
// use Symfony\Bundle\DoctrineBundle\Registry as Doctrine; // for Symfony 2.0.x | |
/** |
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 | |
namespace Acme\AcmeBundle\Controller; | |
use Symfony\Component\HttpFoundation\Response; | |
class SomeController | |
{ | |
public function testAction() | |
{ |
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 | |
use Symfony\Bundle\FrameworkBundle\Controller\Controller, | |
Symfony\Component\HttpFoundation\Request, | |
Sensio\Bundle\FrameworkExtraBundle\Configuration\Method, | |
Sensio\Bundle\FrameworkExtraBundle\Configuration\Route, | |
Sensio\Bundle\FrameworkExtraBundle\Configuration\Template, | |
Pagerfanta\Pagerfanta, | |
Pagerfanta\Adapter\DoctrineORMAdapter, | |
Pagerfanta\Exception\NotValidCurrentPageException; |
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
# app/config/config.yml | |
doctrine: | |
orm: | |
entity_managers: | |
default: | |
dql: | |
numeric_functions: | |
char_length: Acme\DemoBundle\Extension\Doctrine\Query\Mysql\CharLength |
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
{% if form.get('errors') is not empty %} | |
Magic errors display! | |
{% endif %} |
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 | |
/** | |
* DoctrineExtensions Mysql Function Pack | |
* | |
* LICENSE | |
* | |
* This source file is subject to the new BSD license that is bundled | |
* with this package in the file LICENSE.txt. | |
* If you did not receive a copy of the license and are unable to |
OlderNewer