Symfony workshop introductory slides

Download Symfony workshop introductory slides

Post on 22-May-2015

3.379 views

Category:

Technology

3 download

Embed Size (px)

DESCRIPTION

These slides only form a short theoretical introduction for a workshop I gave.

TRANSCRIPT

<ul><li> 1. workshop Ibuildings Presentation Ibuildings The PHP Professionals www.ibuildings.nl +31 118 429 550 info@ibuildings.nlIbuildings Version 10 </li></ul> <p> 2. What will we do? Symfony installation A short overview into the symfony structure An introduction in the symfony CLI Database model creation without phpMyAdmin Creating a simple front-end Creating a simple admin interface Any questions... just ask!Monday, December 10, 2007 2 3. Symfony installation We wont do it, Ill just tell about it ;) PEAR pear channel-discover pear.symfony-project.com pear install symfony/symfony SVN checkout externals Sandbox - no central installationMonday, December 10, 20073 4. Symfony structureMonday, December 10, 2007 4 5. Symfony structure Projectglobal entityholds everythingmost of this outside the document rootweb/ directory should be document root Application Slightly less global entity A group of modules that together form an app Most common use: frontend and backend Module Specific functionality, mostly around one data entity For instance: post for the weblog post, comment forcomments to a weblog post But data might mix... comments to a postMonday, December 10, 2007 5 6. Symfony CLI Your development friend Automates boring tasks likeinitializing your projectinitializing applications and moduleswriting modelsaltering models to reflect schema changeswriting full administration interfacewriting basic (CRUD) actionsdeployment of your applicationMonday, December 10, 2007 6 7. Symfony CLIMonday, December 10, 2007 7 8. Symfony CLI Most important beginner commandssymfony init-project / symfony newsymfony init-app / symfony appsymfony propel-build-modelsymfony propel-build-sql / symfony propel-insert-sqlsymfony propel-generate-crudsymfony init-modulesymfony propel-init-admin And slightly further ahead symfony plugin-install symfony freeze symfony sync Monday, December 10, 2007 8 9. YAML YAML Ain't Markup Language Simple, readable text format Used widely in symfony for configurationMonday, December 10, 20079 10. Creating your database Database schema is defined in YML config/schema.ymlMonday, December 10, 2007 10 11. Creating your database Ensure settings in config/propel.ini are correct symfony propel-build-model symfony propel-build-sql symfony propel-insert-sql or: symfony-propel-build-all Configuring for your app: config/databases.ymlMonday, December 10, 2007 11 12. Creating a simple frontend Creating an empty module symfony init-module frontend simple Creating a CRUD module symfony propel-generate-crud symfony propel-generate-crud frontend weblog Weblog Now you have your basic functionality But you wont need everything visitors need not delete posts visitors need not create posts (well, usually...) So... refactoringMonday, December 10, 2007 12 13. Creating a simple backend symfony propel-init-admin symfony propel-init-admin backend weblogWeblog Module seems empty, but contains all usualadmin functionality Still very flexible, with configuration:generator.ymlMonday, December 10, 2007 13 14. Thats it for the overview Now go to work!source: http://www.ickr.com/photos/bobjagendorf/86120479/ - license: CC Attribution-No Derivative Works 2.0 GenericMonday, December 10, 200714 </p>