SlideShare une entreprise Scribd logo
1  sur  16
Introduction to Fuel
             Phil Sturgeon
  philsturgeon.co.uk | @philsturgeon
WTF is Fuel?
• A “new” PHP framework
• “Combines the best of multiple frameworks”
• Fresh start
• PHP 5.3 only
• Made by a bunch of CodeIgniter guys
It’s freaking brilliant!

• Incredibly lightweight
• Easy to learn
• Huge community
• Helpful forums
• Backwards compatibility is key
• Minimal dependencies
• PHP 5.1.6
It’s PHP5ier!

• Still lightweight
• Everything is a class
• No more $ci =& get_instance();
• PHP 5 autoloading - no loader!
          CodeIgniter                        Fuel

$this->load->library('session');     Session::get('foo');
$this->session->userdata('foo');


• Authentication + Hierarchal MVC (HMVC)
• “Everything” is a driver
• Cascading file system
• No namespacing
  - OAuth_Provider_Facebook
  - OAuthProvider_Facebook
• Splintered: v2.4 versus v3.2
• Great DB builder, not loving the ORM
We stole it!
• Improved Cascading File System
     Autoloader::add_classes(array(
     
     'Mongo_OdmCollection'
 => __DIR__.'/classes/collection.php',
     
     'Mongo_OdmDatabase' 
 => __DIR__.'/classes/database.php',
     
     'Mongo_OdmDocument' 
 => __DIR__.'/classes/document.php',
     
     'Mongo_OdmJSON' 
      => __DIR__.'/classes/json.php',
     ));

• Added Namespacing
        class Config extends FuelCoreConfig {}

• Modules = Routable ‘mini-applications’
• Packages = Installable ‘gem’-like class collections
• Recycled a few other bits
  • Views
  • OAuth
  • Num (Credit card masking and other bits)
•   Command-line tools
•   Database Migrations and ORM bundled in
•   Twig = awesome parser
•   Namespaces by the metric fuck-ton

    namespace AcmeHelloBundleController;
    use SymfonyComponentHttpFoundationResponse;

    class HelloController
    {
        public function indexAction($name)
        {
          return new Response('<html><body>Hello '.$name.'!</
    body></html>');
        }
    }
• Command-line utilities and tasks
                                     $ oil refine robots:protect
• Migrations
  • Database                                           "PROTECT ALL HUMANS"
                                                        _____      /
  • Mongo                                              /_____
  • Whatever                                      ____[*---*/]____
                                                 / # _____/ /# /
                                                / # _.---._/ #/ 
• ORM - lighter and quick                     /    /| |    | /|    
                                             /___/ | | |    | | | ___
                                             | | | | |---| | | | |
• Twig, HAML, Mustache, etc                  |__| _| |_#_| |_/ |__|
                                             // < _//^_ /> //
                                             ||/ |//// /| ||/
• Simple Namespaces                                 |   |   |   |
   • FuelApp                                      |---|   |---|
   • FuelCore                                     |---|
                                                    |   |
                                                            |---|
                                                            |   |
   • Auth                                         |___|   |___|
   • Orm                                          /      /   
                                                   |_____| |_____|
   • Oil                                         |HHHHH| |HHHHH|
   • each module / package
// old usage still valid, will load app/views/example.php
View::forge('example');

// load a Mustache template, will load and parse app/views/
View::forge('example.mustache');

// load a Twig template, will load and parse app/views/example.twig
View::forge('example.twig');

// load a Jade template, will load and parse app/views/example.jade
View::forge('example.jade');

// load a Haml template, will load and parse app/views/example.haml
View::forge('example.haml');

// load a Smarty template, will load and parse app/views/
View::forge('example.smarty');

// load a Dwoo template, ATTENTION: this one expects app/views/
View::forge('example.dwoo');
• Beautiful command line   • Conventions through the nose
• Interactive Debugging    • How the f**k does that work
• Package installation     • Gem conflicts = AGGHHHH!
• http://rubygems.org/     • Consult a wizard if it breaks
• Scaffolding              • ORM restrictions?
• ORM - perfect for RAD
• Beautiful command line      • No conventions
• Interactive Debugging       • Simple OOP
• Package installation        • Application specific packages
• http://cells.fuelphp.com/   • Pretty exceptions
• Scaffolding                 • Scaffold templates
• ORM - perfect for RAD       • DWTFYL ORM
$ oil create blog
$ cd blog
$ oil generate scaffold title:string summary:text body:text
DHH   DH
Any Questions?
Thanks for listening!
philsturgeon.co.uk | @philsturgeon

Contenu connexe

En vedette

Visual Art Sculpture and Architecture
Visual Art Sculpture and ArchitectureVisual Art Sculpture and Architecture
Visual Art Sculpture and ArchitectureJundel Deliman
 
Hydrogen And Fuel Cell Technology For A Sustainable Future
Hydrogen And Fuel Cell Technology For A Sustainable FutureHydrogen And Fuel Cell Technology For A Sustainable Future
Hydrogen And Fuel Cell Technology For A Sustainable FutureGavin Harper
 
Fuel cells presentation
Fuel cells presentationFuel cells presentation
Fuel cells presentationVaibhav Chavan
 
Fuel cells - types, working, construction, fabrication and application
Fuel cells - types, working, construction, fabrication and applicationFuel cells - types, working, construction, fabrication and application
Fuel cells - types, working, construction, fabrication and applicationmegr1412
 
MICROBIAL FUEL CELLS-PPT
MICROBIAL FUEL CELLS-PPTMICROBIAL FUEL CELLS-PPT
MICROBIAL FUEL CELLS-PPTShabeeba V A
 
molten carbonate fuel cell
molten carbonate fuel cellmolten carbonate fuel cell
molten carbonate fuel cellNainesh Patel
 
Solar energy ppt
Solar energy pptSolar energy ppt
Solar energy pptshubhajit_b
 

En vedette (14)

Fuel cells
Fuel cellsFuel cells
Fuel cells
 
Visual Art Sculpture and Architecture
Visual Art Sculpture and ArchitectureVisual Art Sculpture and Architecture
Visual Art Sculpture and Architecture
 
Fuel cells and hydrogen energy systems
Fuel cells and hydrogen energy systemsFuel cells and hydrogen energy systems
Fuel cells and hydrogen energy systems
 
Fuel cell
Fuel cellFuel cell
Fuel cell
 
Fuel cells
Fuel cellsFuel cells
Fuel cells
 
Hydrogen And Fuel Cell Technology For A Sustainable Future
Hydrogen And Fuel Cell Technology For A Sustainable FutureHydrogen And Fuel Cell Technology For A Sustainable Future
Hydrogen And Fuel Cell Technology For A Sustainable Future
 
Fuel Cells
Fuel CellsFuel Cells
Fuel Cells
 
Hydrogen fuel cell
Hydrogen fuel cellHydrogen fuel cell
Hydrogen fuel cell
 
Fuel cells presentation
Fuel cells presentationFuel cells presentation
Fuel cells presentation
 
Fuel cells - types, working, construction, fabrication and application
Fuel cells - types, working, construction, fabrication and applicationFuel cells - types, working, construction, fabrication and application
Fuel cells - types, working, construction, fabrication and application
 
MICROBIAL FUEL CELLS-PPT
MICROBIAL FUEL CELLS-PPTMICROBIAL FUEL CELLS-PPT
MICROBIAL FUEL CELLS-PPT
 
molten carbonate fuel cell
molten carbonate fuel cellmolten carbonate fuel cell
molten carbonate fuel cell
 
Solar energy ppt
Solar energy pptSolar energy ppt
Solar energy ppt
 
Solar Energy
Solar EnergySolar Energy
Solar Energy
 

Similaire à Introduction to Fuel

The Themer's Guide to WP-CLI
The Themer's Guide to WP-CLIThe Themer's Guide to WP-CLI
The Themer's Guide to WP-CLIEdmund Turbin
 
The Themer's Guide to WP-CLI
The Themer's Guide to WP-CLIThe Themer's Guide to WP-CLI
The Themer's Guide to WP-CLIEdmund Turbin
 
HoneyPy & HoneyDB (TriPython)
HoneyPy & HoneyDB (TriPython)HoneyPy & HoneyDB (TriPython)
HoneyPy & HoneyDB (TriPython)Phillip Maddux
 
Mark Collier Keynote - OpenStack Day London June 2014
Mark Collier Keynote -  OpenStack Day London June 2014Mark Collier Keynote -  OpenStack Day London June 2014
Mark Collier Keynote - OpenStack Day London June 2014OpenStack Foundation
 
Tips on how to build Camunda Run for production
Tips on how to build Camunda Run for productionTips on how to build Camunda Run for production
Tips on how to build Camunda Run for productioncamunda services GmbH
 
More Secrets of JavaScript Libraries
More Secrets of JavaScript LibrariesMore Secrets of JavaScript Libraries
More Secrets of JavaScript Librariesjeresig
 
Systems Automation with Puppet
Systems Automation with PuppetSystems Automation with Puppet
Systems Automation with Puppetelliando dias
 
DevOps for Humans - Ansible for Drupal Deployment Victory!
DevOps for Humans - Ansible for Drupal Deployment Victory!DevOps for Humans - Ansible for Drupal Deployment Victory!
DevOps for Humans - Ansible for Drupal Deployment Victory!Jeff Geerling
 
VMTH Project
VMTH ProjectVMTH Project
VMTH ProjectSVDevOps
 
Master Chef class: learn how to quickly cook delightful CQ/AEM infrastructures
Master Chef class: learn how to quickly cook delightful CQ/AEM infrastructuresMaster Chef class: learn how to quickly cook delightful CQ/AEM infrastructures
Master Chef class: learn how to quickly cook delightful CQ/AEM infrastructuresFrançois Le Droff
 
Virtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + PuppetVirtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + PuppetOmar Reygaert
 
Intro to Rails
Intro to Rails Intro to Rails
Intro to Rails epiineg1
 
Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부Hyun-Mook Choi
 
Dev Day 2019: Phillip Krenn – Aggregierte Logging Patterns
Dev Day 2019: Phillip Krenn – Aggregierte Logging PatternsDev Day 2019: Phillip Krenn – Aggregierte Logging Patterns
Dev Day 2019: Phillip Krenn – Aggregierte Logging PatternsDevDay Dresden
 
Desymfony 2011 - Habemus Bundles
Desymfony 2011 - Habemus BundlesDesymfony 2011 - Habemus Bundles
Desymfony 2011 - Habemus BundlesAlbert Jessurum
 

Similaire à Introduction to Fuel (20)

HTML5 Web forms & microdata - Akiva Levi
HTML5 Web forms & microdata - Akiva LeviHTML5 Web forms & microdata - Akiva Levi
HTML5 Web forms & microdata - Akiva Levi
 
The Themer's Guide to WP-CLI
The Themer's Guide to WP-CLIThe Themer's Guide to WP-CLI
The Themer's Guide to WP-CLI
 
The Themer's Guide to WP-CLI
The Themer's Guide to WP-CLIThe Themer's Guide to WP-CLI
The Themer's Guide to WP-CLI
 
HoneyPy & HoneyDB (TriPython)
HoneyPy & HoneyDB (TriPython)HoneyPy & HoneyDB (TriPython)
HoneyPy & HoneyDB (TriPython)
 
T5 Oli Aro
T5 Oli AroT5 Oli Aro
T5 Oli Aro
 
Mark Collier Keynote - OpenStack Day London June 2014
Mark Collier Keynote -  OpenStack Day London June 2014Mark Collier Keynote -  OpenStack Day London June 2014
Mark Collier Keynote - OpenStack Day London June 2014
 
Tips on how to build Camunda Run for production
Tips on how to build Camunda Run for productionTips on how to build Camunda Run for production
Tips on how to build Camunda Run for production
 
More Secrets of JavaScript Libraries
More Secrets of JavaScript LibrariesMore Secrets of JavaScript Libraries
More Secrets of JavaScript Libraries
 
Cooking with Chef
Cooking with ChefCooking with Chef
Cooking with Chef
 
Systems Automation with Puppet
Systems Automation with PuppetSystems Automation with Puppet
Systems Automation with Puppet
 
DevOps for Humans - Ansible for Drupal Deployment Victory!
DevOps for Humans - Ansible for Drupal Deployment Victory!DevOps for Humans - Ansible for Drupal Deployment Victory!
DevOps for Humans - Ansible for Drupal Deployment Victory!
 
VMTH Project
VMTH ProjectVMTH Project
VMTH Project
 
Vmth project
Vmth projectVmth project
Vmth project
 
Master Chef class: learn how to quickly cook delightful CQ/AEM infrastructures
Master Chef class: learn how to quickly cook delightful CQ/AEM infrastructuresMaster Chef class: learn how to quickly cook delightful CQ/AEM infrastructures
Master Chef class: learn how to quickly cook delightful CQ/AEM infrastructures
 
Mojolicious
MojoliciousMojolicious
Mojolicious
 
Virtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + PuppetVirtualization and automation of library software/machines + Puppet
Virtualization and automation of library software/machines + Puppet
 
Intro to Rails
Intro to Rails Intro to Rails
Intro to Rails
 
Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부Fargate 를 이용한 ECS with VPC 1부
Fargate 를 이용한 ECS with VPC 1부
 
Dev Day 2019: Phillip Krenn – Aggregierte Logging Patterns
Dev Day 2019: Phillip Krenn – Aggregierte Logging PatternsDev Day 2019: Phillip Krenn – Aggregierte Logging Patterns
Dev Day 2019: Phillip Krenn – Aggregierte Logging Patterns
 
Desymfony 2011 - Habemus Bundles
Desymfony 2011 - Habemus BundlesDesymfony 2011 - Habemus Bundles
Desymfony 2011 - Habemus Bundles
 

Plus de Phil Sturgeon

API Pain Points (PHPNE)
API Pain Points (PHPNE)API Pain Points (PHPNE)
API Pain Points (PHPNE)Phil Sturgeon
 
PHP-FIG: Past, Present and Future
PHP-FIG: Past, Present and FuturePHP-FIG: Past, Present and Future
PHP-FIG: Past, Present and FuturePhil Sturgeon
 
Become Master of Your Own Universe - DIBI 2013
Become Master of Your Own Universe - DIBI 2013Become Master of Your Own Universe - DIBI 2013
Become Master of Your Own Universe - DIBI 2013Phil Sturgeon
 
Laravel and Composer
Laravel and ComposerLaravel and Composer
Laravel and ComposerPhil Sturgeon
 
Why I &lt;3 Laravel 4
Why I &lt;3 Laravel 4Why I &lt;3 Laravel 4
Why I &lt;3 Laravel 4Phil Sturgeon
 
Running an Open-Source CodeIgniter project
Running an Open-Source CodeIgniter projectRunning an Open-Source CodeIgniter project
Running an Open-Source CodeIgniter projectPhil Sturgeon
 

Plus de Phil Sturgeon (10)

API Pain Points (PHPNE)
API Pain Points (PHPNE)API Pain Points (PHPNE)
API Pain Points (PHPNE)
 
Api pain points
Api pain pointsApi pain points
Api pain points
 
Api pain points
Api pain pointsApi pain points
Api pain points
 
PHP-FIG: Past, Present and Future
PHP-FIG: Past, Present and FuturePHP-FIG: Past, Present and Future
PHP-FIG: Past, Present and Future
 
Become Master of Your Own Universe - DIBI 2013
Become Master of Your Own Universe - DIBI 2013Become Master of Your Own Universe - DIBI 2013
Become Master of Your Own Universe - DIBI 2013
 
Laravel and Composer
Laravel and ComposerLaravel and Composer
Laravel and Composer
 
Why I &lt;3 Laravel 4
Why I &lt;3 Laravel 4Why I &lt;3 Laravel 4
Why I &lt;3 Laravel 4
 
CodeIgniter 3.0
CodeIgniter 3.0CodeIgniter 3.0
CodeIgniter 3.0
 
Cms expo
Cms expoCms expo
Cms expo
 
Running an Open-Source CodeIgniter project
Running an Open-Source CodeIgniter projectRunning an Open-Source CodeIgniter project
Running an Open-Source CodeIgniter project
 

Dernier

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 

Dernier (20)

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 

Introduction to Fuel

  • 1. Introduction to Fuel Phil Sturgeon philsturgeon.co.uk | @philsturgeon
  • 2. WTF is Fuel? • A “new” PHP framework • “Combines the best of multiple frameworks” • Fresh start • PHP 5.3 only • Made by a bunch of CodeIgniter guys
  • 3.
  • 4. It’s freaking brilliant! • Incredibly lightweight • Easy to learn • Huge community • Helpful forums • Backwards compatibility is key • Minimal dependencies • PHP 5.1.6
  • 5. It’s PHP5ier! • Still lightweight • Everything is a class • No more $ci =& get_instance(); • PHP 5 autoloading - no loader! CodeIgniter Fuel $this->load->library('session'); Session::get('foo'); $this->session->userdata('foo'); • Authentication + Hierarchal MVC (HMVC) • “Everything” is a driver
  • 6. • Cascading file system • No namespacing - OAuth_Provider_Facebook - OAuthProvider_Facebook • Splintered: v2.4 versus v3.2 • Great DB builder, not loving the ORM
  • 7. We stole it! • Improved Cascading File System Autoloader::add_classes(array( 'Mongo_OdmCollection' => __DIR__.'/classes/collection.php', 'Mongo_OdmDatabase' => __DIR__.'/classes/database.php', 'Mongo_OdmDocument' => __DIR__.'/classes/document.php', 'Mongo_OdmJSON' => __DIR__.'/classes/json.php', )); • Added Namespacing class Config extends FuelCoreConfig {} • Modules = Routable ‘mini-applications’ • Packages = Installable ‘gem’-like class collections • Recycled a few other bits • Views • OAuth • Num (Credit card masking and other bits)
  • 8. Command-line tools • Database Migrations and ORM bundled in • Twig = awesome parser • Namespaces by the metric fuck-ton namespace AcmeHelloBundleController; use SymfonyComponentHttpFoundationResponse; class HelloController { public function indexAction($name) { return new Response('<html><body>Hello '.$name.'!</ body></html>'); } }
  • 9. • Command-line utilities and tasks $ oil refine robots:protect • Migrations • Database "PROTECT ALL HUMANS" _____ / • Mongo /_____ • Whatever ____[*---*/]____ / # _____/ /# / / # _.---._/ #/ • ORM - lighter and quick / /| | | /| /___/ | | | | | | ___ | | | | |---| | | | | • Twig, HAML, Mustache, etc |__| _| |_#_| |_/ |__| // < _//^_ /> // ||/ |//// /| ||/ • Simple Namespaces | | | | • FuelApp |---| |---| • FuelCore |---| | | |---| | | • Auth |___| |___| • Orm / / |_____| |_____| • Oil |HHHHH| |HHHHH| • each module / package
  • 10. // old usage still valid, will load app/views/example.php View::forge('example'); // load a Mustache template, will load and parse app/views/ View::forge('example.mustache'); // load a Twig template, will load and parse app/views/example.twig View::forge('example.twig'); // load a Jade template, will load and parse app/views/example.jade View::forge('example.jade'); // load a Haml template, will load and parse app/views/example.haml View::forge('example.haml'); // load a Smarty template, will load and parse app/views/ View::forge('example.smarty'); // load a Dwoo template, ATTENTION: this one expects app/views/ View::forge('example.dwoo');
  • 11.
  • 12. • Beautiful command line • Conventions through the nose • Interactive Debugging • How the f**k does that work • Package installation • Gem conflicts = AGGHHHH! • http://rubygems.org/ • Consult a wizard if it breaks • Scaffolding • ORM restrictions? • ORM - perfect for RAD
  • 13. • Beautiful command line • No conventions • Interactive Debugging • Simple OOP • Package installation • Application specific packages • http://cells.fuelphp.com/ • Pretty exceptions • Scaffolding • Scaffold templates • ORM - perfect for RAD • DWTFYL ORM
  • 14. $ oil create blog $ cd blog $ oil generate scaffold title:string summary:text body:text
  • 15. DHH DH
  • 16. Any Questions? Thanks for listening! philsturgeon.co.uk | @philsturgeon

Notes de l'éditeur

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n