Download - A Practical Introduction to Symfony2

Transcript
Page 1: A Practical Introduction to Symfony2

A Practical Introductionto Symfony2

Kris Wallsmith

PHP Matsuri • October 2, 2010

Saturday, October 2, 2010

Page 2: A Practical Introduction to Symfony2

@kriswallsmith

• Release Manager for symfony 1.3 & 1.4

• Doctrine contributor

• Senior Software Engineer at

• 10 years experience in web development

• Open source evangelist and international speaker

Saturday, October 2, 2010

Page 3: A Practical Introduction to Symfony2

the evolution of symfony

• Mojavi 3

• symfony (2007)

• Symfony2 (2011)

Saturday, October 2, 2010

Page 4: A Practical Introduction to Symfony2

a quick note for thecase-sensitive among us

Saturday, October 2, 2010

Page 5: A Practical Introduction to Symfony2

talk about “symfony”

Saturday, October 2, 2010

Page 6: A Practical Introduction to Symfony2

talk about “symfony 1”

Saturday, October 2, 2010

Page 7: A Practical Introduction to Symfony2

talk about “Symfony2”

Saturday, October 2, 2010

Page 8: A Practical Introduction to Symfony2

there is no “Symfony 1”

Saturday, October 2, 2010

Page 9: A Practical Introduction to Symfony2

there is no “symfony 2”

Saturday, October 2, 2010

Page 10: A Practical Introduction to Symfony2

there is no “Symfony 2”

Saturday, October 2, 2010

Page 11: A Practical Introduction to Symfony2

there is no “Symfony 2”

less search-friendly

{Saturday, October 2, 2010

Page 12: A Practical Introduction to Symfony2

Symfony2

Saturday, October 2, 2010

Page 13: A Practical Introduction to Symfony2

Symfony2#

Saturday, October 2, 2010

Page 14: A Practical Introduction to Symfony2

the evolution of symfony

• Mojavi 3

• symfony (2007)

• Symfony2 (2011)

Saturday, October 2, 2010

Page 15: A Practical Introduction to Symfony2

what’s old?

Saturday, October 2, 2010

Page 16: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

Saturday, October 2, 2010

Page 17: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

• don’t reinvent the wheel

Saturday, October 2, 2010

Page 18: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

• don’t reinvent the wheel

• loosely-coupled components

Saturday, October 2, 2010

Page 19: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

• don’t reinvent the wheel

• loosely-coupled components

• predictable conventions

Saturday, October 2, 2010

Page 20: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

• don’t reinvent the wheel

• loosely-coupled components

• predictable conventions

• highly configurable

Saturday, October 2, 2010

Page 21: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

• don’t reinvent the wheel

• loosely-coupled components

• predictable conventions

• highly configurable

• testable

Saturday, October 2, 2010

Page 22: A Practical Introduction to Symfony2

what’s old?

• same philosophy as symfony 1

• don’t reinvent the wheel

• loosely-coupled components

• predictable conventions

• highly configurable

• testable

• awesome developer tools

Saturday, October 2, 2010

Page 23: A Practical Introduction to Symfony2

what’s new?

Saturday, October 2, 2010

Page 24: A Practical Introduction to Symfony2

what’s new?

• PHP 5.3

• a brand new foundation

Saturday, October 2, 2010

Page 25: A Practical Introduction to Symfony2

what’s new?

• PHP 5.3

• a brand new foundation

• more smart, more lazy

Saturday, October 2, 2010

Page 26: A Practical Introduction to Symfony2

what’s new?

• PHP 5.3

• a brand new foundation

• more smart, more lazy

• REALLY REALLY FAST

Saturday, October 2, 2010

Page 27: A Practical Introduction to Symfony2

what’s new?

• PHP 5.3

• a brand new foundation

• more smart, more lazy

• REALLY REALLY FAST

Saturday, October 2, 2010

Page 28: A Practical Introduction to Symfony2

PHP 5.3

Saturday, October 2, 2010

Page 29: A Practical Introduction to Symfony2

PHP 5.3

• namespaces

• closures

Saturday, October 2, 2010

Page 30: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 31: A Practical Introduction to Symfony2

HTTP\Message\Request

Saturday, October 2, 2010

Page 32: A Practical Introduction to Symfony2

HTTP\Message\Request

Saturday, October 2, 2010

Page 33: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 34: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 35: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 36: A Practical Introduction to Symfony2

HTTP\Client\Request

Saturday, October 2, 2010

Page 37: A Practical Introduction to Symfony2

HTTP\Client\Request

Saturday, October 2, 2010

Page 38: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 39: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 40: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 41: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 42: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 43: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 44: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 45: A Practical Introduction to Symfony2

closures

• anonymous functions

• lambda functions

Saturday, October 2, 2010

Page 46: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 47: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 48: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 49: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 50: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 51: A Practical Introduction to Symfony2

a new foundation

Saturday, October 2, 2010

Page 52: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

Saturday, October 2, 2010

Page 53: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• Kernel

Saturday, October 2, 2010

Page 54: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• Kernel

• Request

Saturday, October 2, 2010

Page 55: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• Kernel

• Request

• Controller

Saturday, October 2, 2010

Page 56: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• Kernel

• Request

• Controller

• Response

Saturday, October 2, 2010

Page 57: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

Saturday, October 2, 2010

Page 58: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• index.php creates a Kernel

Saturday, October 2, 2010

Page 59: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• index.php creates a Kernel

• the kernel creates a Request

Saturday, October 2, 2010

Page 60: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• index.php creates a Kernel

• the kernel creates a Request

• the kernel passes the Request to the ControllerResolver

Saturday, October 2, 2010

Page 61: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• index.php creates a Kernel

• the kernel creates a Request

• the kernel passes the Request to the ControllerResolver

• the ControllerResolver returns a callable

Saturday, October 2, 2010

Page 62: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• index.php creates a Kernel

• the kernel creates a Request

• the kernel passes the Request to the ControllerResolver

• the ControllerResolver returns a callable

• the kernel calls the callable

Saturday, October 2, 2010

Page 63: A Practical Introduction to Symfony2

anatomy of a Symfony2 request

• index.php creates a Kernel

• the kernel creates a Request

• the kernel passes the Request to the ControllerResolver

• the ControllerResolver returns a callable

• the kernel calls the callable

• the callable returns a Response

Saturday, October 2, 2010

Page 64: A Practical Introduction to Symfony2

Silexhttp://github.com/fabpot/Silex

Saturday, October 2, 2010

Page 65: A Practical Introduction to Symfony2

just enough, nothing more

Saturday, October 2, 2010

Page 66: A Practical Introduction to Symfony2

Saturday, October 2, 2010

Page 67: A Practical Introduction to Symfony2

switch ($_GET['pg'])case 'edit':// ...

Saturday, October 2, 2010

Page 68: A Practical Introduction to Symfony2

switch ($_GET['pg'])case 'edit':// ...

Saturday, October 2, 2010

Page 69: A Practical Introduction to Symfony2

Any volunteers to rewrite WordPress in Silex?

Saturday, October 2, 2010

Page 70: A Practical Introduction to Symfony2

quick tour

Saturday, October 2, 2010

Page 71: A Practical Introduction to Symfony2

frontend/src/web/

Saturday, October 2, 2010

Page 72: A Practical Introduction to Symfony2

frontend/ FrontendKernel.php cache/ config/ console logs/ phpunit.xml

Saturday, October 2, 2010

Page 73: A Practical Introduction to Symfony2

src/ autoload.php Application/ Bundle/ vendor/ symfony/ doctrine/

Saturday, October 2, 2010

Page 74: A Practical Introduction to Symfony2

web/ css/ images/ index.php index_dev.php js/

Saturday, October 2, 2010

Page 75: A Practical Introduction to Symfony2

../ MainBundle/ Controller/ MainBundle.php Resources/ config/ views/ Tests/

Saturday, October 2, 2010

Page 76: A Practical Introduction to Symfony2

How do I use it?

Saturday, October 2, 2010

Page 77: A Practical Introduction to Symfony2

# frontend/config/routing.ymlhomepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 78: A Practical Introduction to Symfony2

// src/Application/MainBundle/Controller/MainController.phpnamespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

Saturday, October 2, 2010

Page 79: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

homepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 80: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

homepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 81: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

homepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 82: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

homepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 83: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

homepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 84: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class MainController extends Controller{ public function indexAction() { return $this->render('MainBundle:Main:index.php'); }}

homepage: pattern: / defaults: _controller: MainBundle:Main:index requirements: _method: get

Saturday, October 2, 2010

Page 85: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class BlogController extends Controller { public function showArticleAction($slug, $year) { // ... return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article)); }}

homepage: pattern: /:year/:slug defaults: _controller: MainBundle:Blog:showArticle requirements: year: \d{4}

Saturday, October 2, 2010

Page 86: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class BlogController extends Controller { public function showArticleAction($slug, $year) { // ... return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article)); }}

homepage: pattern: /:year/:slug defaults: _controller: MainBundle:Blog:showArticle requirements: year: \d{4}

Saturday, October 2, 2010

Page 87: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class BlogController extends Controller { public function showArticleAction($slug, $year) { // ... return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article)); }}

homepage: pattern: /:year/:slug defaults: _controller: MainBundle:Blog:showArticle requirements: year: \d{4}

Saturday, October 2, 2010

Page 88: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class BlogController extends Controller { public function showArticleAction($slug, $year) { // ... return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article)); }}

homepage: pattern: /:year/:slug defaults: _controller: MainBundle:Blog:showArticle requirements: year: \d{4}

Saturday, October 2, 2010

Page 89: A Practical Introduction to Symfony2

namespace Application\MainBundle\Controller;

class BlogController extends Controller { public function showArticleAction($slug, $year) { // ... return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article)); }}

homepage: pattern: /:year/:slug defaults: _controller: MainBundle:Blog:showArticle requirements: year: \d{4}

Saturday, October 2, 2010

Page 90: A Practical Introduction to Symfony2

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

Saturday, October 2, 2010

Page 91: A Practical Introduction to Symfony2

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article));

Saturday, October 2, 2010

Page 92: A Practical Introduction to Symfony2

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article));

Saturday, October 2, 2010

Page 93: A Practical Introduction to Symfony2

return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article));

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

Saturday, October 2, 2010

Page 94: A Practical Introduction to Symfony2

return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article));

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

Saturday, October 2, 2010

Page 95: A Practical Introduction to Symfony2

return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article));

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

Saturday, October 2, 2010

Page 96: A Practical Introduction to Symfony2

return $this->render('MainBundle:Blog:showArticle.php', array('article' => $article));

MainBundle/Resources/ config/ views/ Blog/ showArticle.php Main/ error404.php index.php layout.php

Saturday, October 2, 2010

Page 97: A Practical Introduction to Symfony2

MainBundle/Resources/ config/ views/ Blog/ showArticle.twig Main/ error404.php index.php layout.php

return $this->render('MainBundle:Blog:showArticle.twig', array('article' => $article));

Saturday, October 2, 2010

Page 98: A Practical Introduction to Symfony2

MainBundle/Resources/ config/ views/ Blog/ showArticle.twig Main/ error404.php index.php layout.php

return $this->render('MainBundle:Blog:showArticle.twig', array('article' => $article));

Saturday, October 2, 2010

Page 99: A Practical Introduction to Symfony2

TwigThe flexible, fast, and secure template language for PHP

http://twig-project.org

Saturday, October 2, 2010

Page 100: A Practical Introduction to Symfony2

symfony 1

Saturday, October 2, 2010

Page 101: A Practical Introduction to Symfony2

symfony 1

• templates

Saturday, October 2, 2010

Page 102: A Practical Introduction to Symfony2

symfony 1

• templates

• layouts

Saturday, October 2, 2010

Page 103: A Practical Introduction to Symfony2

symfony 1

• templates

• layouts

• slots

Saturday, October 2, 2010

Page 104: A Practical Introduction to Symfony2

symfony 1

• templates

• layouts

• slots

• components

Saturday, October 2, 2010

Page 105: A Practical Introduction to Symfony2

symfony 1

• templates

• layouts

• slots

• components

• partials

Saturday, October 2, 2010

Page 106: A Practical Introduction to Symfony2

symfony 1

• templates

• layouts

• slots

• components

• partials

• component slots

Saturday, October 2, 2010

Page 107: A Practical Introduction to Symfony2

fewer concepts, more power

Saturday, October 2, 2010

Page 108: A Practical Introduction to Symfony2

Symfony2

Saturday, October 2, 2010

Page 109: A Practical Introduction to Symfony2

Symfony2

• templates

Saturday, October 2, 2010

Page 110: A Practical Introduction to Symfony2

Symfony2

• templates

• slots

Saturday, October 2, 2010

Page 111: A Practical Introduction to Symfony2

Symfony2

• templates

• slots } fewer concepts, more power

Saturday, October 2, 2010

Page 112: A Practical Introduction to Symfony2

<?php $view->extend('MainBundle::layout.php') ?>

<?php foreach ($people as $person): ?>

<?php $view->render( 'MainBundle:Person:thumbnail', array('person' => $person) ) ?>

<?php endforeach; ?>

Saturday, October 2, 2010

Page 113: A Practical Introduction to Symfony2

<?php $view->extend('MainBundle::layout.php') ?>

<?php foreach ($people as $person): ?>

<?php $view->render( 'MainBundle:Person:thumbnail', array('person' => $person) ) ?>

<?php endforeach; ?>

decorate_with()

Saturday, October 2, 2010

Page 114: A Practical Introduction to Symfony2

<?php $view->extend('MainBundle::layout.php') ?>

<?php foreach ($people as $person): ?>

<?php $view->render( 'MainBundle:Person:thumbnail', array('person' => $person) ) ?>

<?php endforeach; ?>

Saturday, October 2, 2010

Page 115: A Practical Introduction to Symfony2

<?php $view->extend('MainBundle::layout.php') ?>

<?php foreach ($people as $person): ?>

<?php $view->render( 'MainBundle:Person:thumbnail', array('person' => $person) ) ?>

<?php endforeach; ?>

Saturday, October 2, 2010

Page 116: A Practical Introduction to Symfony2

<?php $view->extend('MainBundle::layout.php') ?>

<?php foreach ($people as $person): ?>

<?php $view->render( 'MainBundle:Person:thumbnail', array('person' => $person) ) ?>

<?php endforeach; ?>

include_partial()

Saturday, October 2, 2010

Page 117: A Practical Introduction to Symfony2

<?php $view->extend('MainBundle::layout.php') ?>

<?php foreach ($people as $person): ?>

<?php $view->render( 'MainBundle:Person:thumbnail', array('person' => $person) ) ?>

<?php endforeach; ?>

Saturday, October 2, 2010

Page 118: A Practical Introduction to Symfony2

helpers

Saturday, October 2, 2010

Page 119: A Practical Introduction to Symfony2

<?php $view['slots']->set('title', 'Hi!') ?>

<?php $view['slots']->start('sidebar') ?>

My awesome sidebar!

<?php $view['slots']->stop() ?>

Saturday, October 2, 2010

Page 120: A Practical Introduction to Symfony2

<?php $view['slots']->set('title', 'Hi!') ?>

<?php $view['slots']->start('sidebar') ?>

My awesome sidebar!

<?php $view['slots']->stop() ?>

Saturday, October 2, 2010

Page 121: A Practical Introduction to Symfony2

helpers are objects

Saturday, October 2, 2010

Page 122: A Practical Introduction to Symfony2

$view['javascripts']->add('script.js');echo $view['javascripts'];

echo $view['assets']->getUrl('logo.gif');

echo $view['router']->generate( 'person_show', array('username' => $username));

$view['actions']->output('MainBundle:Search:form');

use_javascript()

Saturday, October 2, 2010

Page 123: A Practical Introduction to Symfony2

$view['javascripts']->add('script.js');echo $view['javascripts'];

echo $view['assets']->getUrl('logo.gif');

echo $view['router']->generate( 'person_show', array('username' => $username));

$view['actions']->output('MainBundle:Search:form');

include_javascripts()

Saturday, October 2, 2010

Page 124: A Practical Introduction to Symfony2

$view['javascripts']->add('script.js');echo $view['javascripts'];

echo $view['assets']->getUrl('logo.gif');

echo $view['router']->generate( 'person_show', array('username' => $username));

$view['actions']->output('MainBundle:Search:form');

public_path()

Saturday, October 2, 2010

Page 125: A Practical Introduction to Symfony2

$view['javascripts']->add('script.js');echo $view['javascripts'];

echo $view['assets']->getUrl('logo.gif');

echo $view['router']->generate( 'person_show', array('username' => $username));

$view['actions']->output('MainBundle:Search:form');url_for()

Saturday, October 2, 2010

Page 126: A Practical Introduction to Symfony2

$view['javascripts']->add('script.js');echo $view['javascripts'];

echo $view['assets']->getUrl('logo.gif');

echo $view['router']->generate( 'person_show', array('username' => $username));

$view['actions']->output('MainBundle:Search:form');

include_component()

Saturday, October 2, 2010

Page 127: A Practical Introduction to Symfony2

dependency injection

Saturday, October 2, 2010

Page 128: A Practical Introduction to Symfony2

lazy objects

Saturday, October 2, 2010

Page 129: A Practical Introduction to Symfony2

if you want me to fooyou better give me the foo-er“

”Saturday, October 2, 2010

Page 130: A Practical Introduction to Symfony2

class User{ protected $session;

public function __construct(Session $session) { $this->session = $session; }}

Saturday, October 2, 2010

Page 131: A Practical Introduction to Symfony2

class User{ protected $session;

public function __construct() { $this->session = Session::factory(); }}

Saturday, October 2, 2010

Page 132: A Practical Introduction to Symfony2

class User{ protected $session;

public function __construct() { $this->session = Session::factory(); }}

Saturday, October 2, 2010

Page 133: A Practical Introduction to Symfony2

$session = $this->getMock('Session') ->expects($this->any()) ->method('get') ->with('foo') ->will($this->returnValue('bar'));

// inject the mock object!$user = new User($session);

$this->assertEquals('bar', $user->getSessionVar('foo'));

Saturday, October 2, 2010

Page 134: A Practical Introduction to Symfony2

dependency injection container

• a configuration layer

• creates a "container" that manages the creation of objects

• “teach” the container

• using xml, yaml, php, ini(or some combination)

Saturday, October 2, 2010

Page 135: A Practical Introduction to Symfony2

services: session: class: Session

user: class: User arguments: - @session

Saturday, October 2, 2010

Page 136: A Practical Introduction to Symfony2

public function getUserService(){ if (isset($this->shared['user'])) return $this->shared['user'];

$user = new User( $this->getSessionService() );

$this->shared['user'] = $user;

return $user;}

Saturday, October 2, 2010

Page 137: A Practical Introduction to Symfony2

// get one service by name$container->get('user');

Saturday, October 2, 2010

Page 138: A Practical Introduction to Symfony2

// find many services by "tag"$c->findTaggedServiceIds('my_tag');

Saturday, October 2, 2010

Page 139: A Practical Introduction to Symfony2

services: foo_helper: class: Foo tags: - name: my_tag

Saturday, October 2, 2010

Page 140: A Practical Introduction to Symfony2

container parameters

Saturday, October 2, 2010

Page 141: A Practical Introduction to Symfony2

parameters: foo.class: Foo

services: foo: class: %foo.class%

Saturday, October 2, 2010

Page 142: A Practical Introduction to Symfony2

parameters: foo.class: Foo

services: foo: class: %foo.class%

Saturday, October 2, 2010

Page 143: A Practical Introduction to Symfony2

parameters: foo.class: Foo

services: foo: class: %foo.class%

Saturday, October 2, 2010

Page 144: A Practical Introduction to Symfony2

dependency injection extensionssemantic configuration

Saturday, October 2, 2010

Page 145: A Practical Introduction to Symfony2

doctrine.dbal: dbname: xxx user: xxx password: xxx

doctrine.orm: ~

Saturday, October 2, 2010

Page 146: A Practical Introduction to Symfony2

awesome developer tools

Saturday, October 2, 2010

Page 147: A Practical Introduction to Symfony2

Web Debug Toolbar

Saturday, October 2, 2010

Page 148: A Practical Introduction to Symfony2

Web Debug Toolbar

Saturday, October 2, 2010

Page 149: A Practical Introduction to Symfony2

Web Debug Toolbar

Saturday, October 2, 2010

Page 150: A Practical Introduction to Symfony2

Web Profiler

Saturday, October 2, 2010

Page 151: A Practical Introduction to Symfony2

Web Profiler

Saturday, October 2, 2010

Page 152: A Practical Introduction to Symfony2

Web Profiler

Saturday, October 2, 2010

Page 153: A Practical Introduction to Symfony2

Web Profiler

Saturday, October 2, 2010

Page 154: A Practical Introduction to Symfony2

Web Profiler

Saturday, October 2, 2010

Page 155: A Practical Introduction to Symfony2

Questions?

Saturday, October 2, 2010

Page 156: A Practical Introduction to Symfony2

OpenSky is Hiring!http://engineering.shopopensky.com

Please contact me if you're interested.

Saturday, October 2, 2010

Page 157: A Practical Introduction to Symfony2

OpenSky is Hiring!http://engineering.shopopensky.com

Please contact me if you're interested.

Saturday, October 2, 2010

Page 158: A Practical Introduction to Symfony2

symfony-reloaded.org

Saturday, October 2, 2010