SlideShare a Scribd company logo
1 of 28
Download to read offline
Becoming a PHP ninja
       Md. Emran Hasan
  emran@rightbrainsolution.com
About me
<about>

 Doing PHP for 5+ years

 Developer, consultant, manager

 CTO, Right Brain Solution Ltd.

 Previous: SWI, Pageflakes, Trippert Labs.

</about>
Introduction
This presentation is about:
– development practices

– personal development
DEVELOPMENT PRACTICES
1. Coding standards
• Readable code

• Easy to maintain

• Documentation
<?

// Method 1
if($condition)
function1($a, $b, $c);
if($i < 7 && $j > 8 || $k == 4)
a($i);

?>
<?php

// Method 2
if ($condition)
{
   getUser($id, $username, $key);
}

If (($i < 7) && (($j < 8) || ($k == 4)))
{
   displayGraph($value);
}
• PEAR Coding Standards
 http://pear.php.net/manual/en/standards.php


• Zend Framework Coding Standards
 http://framework.zend.com/manual/en/coding-standard.html


• eZ Components Implementation guidelines
 http://www.ezcomponents.org/contributing/coding_standards
2. Code Commenting
• Reduced code understanding time

• Serves as a documentation

• Answer the question: WHY??
/**
* Add number
*
* This function will take two integer numbers and will
* return the addition result of them.
*
* @param int first number
* @param int second number
* @return int addition result
*/
function addNumbers($firstNum, $secondNum)
3. Code re-use
• Re-use code across projects

• Refactor every now & then

• Don’t Repeat Yourself (DRY)
4. Code testing
• Gives confidence

• Unit testing in rescue

• Test Driven Development (TDD)
• PHPUnit - http://www.phpunit.de
• SimpleTest - http://www.simpletest.org
5. PHP Framework
• Forces good structure

• Ready to use libraries

• Solves most real-life problems


               80% - 20%
•   Zend Framework - http://framework.zend.com
•   CodeIgniter - http://www.codeigniter.com
•   CakePHP - http://cakephp.org/
•   Symfony - http://www.symfony-project.org
6. Source Control (SCM)
• Your own personal UNDO

• Compare, rollback, track source code

• Must for team collaboration
• Subversion - http://subversion.tigris.org

• Git - http://git-scm.com
7. PHP IDE
• Increased productivity

• Reduced error in code

• Debugging, profiling
• Eclipse PDT
  http://www.eclipse.org/pdt

• Netbeans IDE
  http://www.netbeans.org

• NuSphere PHPEd
  http://www.nusphere.com

• Zend Studio for Eclipse
  http://www.zend.com/en/products/studio
8. Quality Code
Your PHP code should
  – be simple

  – get the job done

  – be secure

  – be scalable

  – be maintainable
PERSONAL DEVELOPMENT
9. Being Communicative
• Increased productivity

• Reduces confusion

• Builds synergy in team
10. Being Agile
• Working iteratively and incrementally

• Being responsible

• Being open minded
11. Updating yourself
• Trying new technology

• Reading blogs

• Get updated through RSS
• Planet PHP – http://planet-php.net

• PHPDeveloper – http://phpdeveloper.org

• Sitepoint – http://sitepoint.com

• PHP Classes – http://phpclasses.org
12. Community involvement
• Starting to write blog

• Participate in forum and communities

• Contribute in open source projects
Questions?
Contact

    +880 161 PHPFOUR
        @phpfour
    phpfour@gmail.com
http://www.phpfour.com/blog

More Related Content

What's hot

Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Clark Everetts
 
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Pantheon
 
30 Skills to Master to Become a Senior Software Engineer
30 Skills to Master to Become a Senior Software Engineer30 Skills to Master to Become a Senior Software Engineer
30 Skills to Master to Become a Senior Software EngineerSean Coates
 
mod_php vs FastCGI vs FPM vs CLI
mod_php vs FastCGI vs FPM vs CLImod_php vs FastCGI vs FPM vs CLI
mod_php vs FastCGI vs FPM vs CLIJacques Woodcock
 
Why Your Site is Slow: Performance Answers for Your Clients
Why Your Site is Slow: Performance Answers for Your ClientsWhy Your Site is Slow: Performance Answers for Your Clients
Why Your Site is Slow: Performance Answers for Your ClientsPantheon
 
Containerizing legacy applications
Containerizing legacy applicationsContainerizing legacy applications
Containerizing legacy applicationsAndrew Kirkpatrick
 
Behaviour testing for single-page applications and API’s
Behaviour testing for single-page applications and API’sBehaviour testing for single-page applications and API’s
Behaviour testing for single-page applications and API’sAndrew Kirkpatrick
 
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
 
Using Zend Framework 2 Book Presentation
Using Zend Framework 2 Book PresentationUsing Zend Framework 2 Book Presentation
Using Zend Framework 2 Book Presentationolegkrivtsov
 
Continuous Integration Is for Teams: Moving past buzzword driven development
Continuous Integration Is for Teams: Moving past buzzword driven development Continuous Integration Is for Teams: Moving past buzzword driven development
Continuous Integration Is for Teams: Moving past buzzword driven development Pantheon
 
Stop making, start composing - Using Composer for Drupal development
Stop making, start composing - Using Composer for Drupal developmentStop making, start composing - Using Composer for Drupal development
Stop making, start composing - Using Composer for Drupal developmentkaspergarnaes
 
FuelPHP presentation - PeoplePerHour workshop
FuelPHP presentation - PeoplePerHour workshopFuelPHP presentation - PeoplePerHour workshop
FuelPHP presentation - PeoplePerHour workshopFotis Alexandrou
 
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20Michael Lihs
 
Intro to JavaScript Tooling in Visual Studio Code
Intro to JavaScript Tooling in Visual Studio CodeIntro to JavaScript Tooling in Visual Studio Code
Intro to JavaScript Tooling in Visual Studio CodeColdFusionConference
 
wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...Andreas - Creten
 
FuelPHP - a PHP HMVC Framework by silicongulf.com
FuelPHP - a PHP HMVC Framework by silicongulf.comFuelPHP - a PHP HMVC Framework by silicongulf.com
FuelPHP - a PHP HMVC Framework by silicongulf.comChristopher Cubos
 
10 things you should know about django
10 things you should know about django10 things you should know about django
10 things you should know about djangoAdieu
 
"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012
"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012
"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012Blend Interactive
 

What's hot (20)

Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017
 
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
 
30 Skills to Master to Become a Senior Software Engineer
30 Skills to Master to Become a Senior Software Engineer30 Skills to Master to Become a Senior Software Engineer
30 Skills to Master to Become a Senior Software Engineer
 
mod_php vs FastCGI vs FPM vs CLI
mod_php vs FastCGI vs FPM vs CLImod_php vs FastCGI vs FPM vs CLI
mod_php vs FastCGI vs FPM vs CLI
 
Why Your Site is Slow: Performance Answers for Your Clients
Why Your Site is Slow: Performance Answers for Your ClientsWhy Your Site is Slow: Performance Answers for Your Clients
Why Your Site is Slow: Performance Answers for Your Clients
 
Containerizing legacy applications
Containerizing legacy applicationsContainerizing legacy applications
Containerizing legacy applications
 
Behaviour testing for single-page applications and API’s
Behaviour testing for single-page applications and API’sBehaviour testing for single-page applications and API’s
Behaviour testing for single-page applications and API’s
 
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
 
Using Zend Framework 2 Book Presentation
Using Zend Framework 2 Book PresentationUsing Zend Framework 2 Book Presentation
Using Zend Framework 2 Book Presentation
 
Continuous Integration Is for Teams: Moving past buzzword driven development
Continuous Integration Is for Teams: Moving past buzzword driven development Continuous Integration Is for Teams: Moving past buzzword driven development
Continuous Integration Is for Teams: Moving past buzzword driven development
 
Stop making, start composing - Using Composer for Drupal development
Stop making, start composing - Using Composer for Drupal developmentStop making, start composing - Using Composer for Drupal development
Stop making, start composing - Using Composer for Drupal development
 
FuelPHP presentation - PeoplePerHour workshop
FuelPHP presentation - PeoplePerHour workshopFuelPHP presentation - PeoplePerHour workshop
FuelPHP presentation - PeoplePerHour workshop
 
FuelPHP
FuelPHPFuelPHP
FuelPHP
 
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
 
Intro to JavaScript Tooling in Visual Studio Code
Intro to JavaScript Tooling in Visual Studio CodeIntro to JavaScript Tooling in Visual Studio Code
Intro to JavaScript Tooling in Visual Studio Code
 
wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...
 
FuelPHP - a PHP HMVC Framework by silicongulf.com
FuelPHP - a PHP HMVC Framework by silicongulf.comFuelPHP - a PHP HMVC Framework by silicongulf.com
FuelPHP - a PHP HMVC Framework by silicongulf.com
 
Improving qa on php projects
Improving qa on php projectsImproving qa on php projects
Improving qa on php projects
 
10 things you should know about django
10 things you should know about django10 things you should know about django
10 things you should know about django
 
"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012
"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012
"Building Modern PHP Applications" - Jackson Murtha, South Dakota Code Camp 2012
 

Similar to Becoming A Php Ninja

Enterprise PHP Development - ZendCon 2008
Enterprise PHP Development - ZendCon 2008Enterprise PHP Development - ZendCon 2008
Enterprise PHP Development - ZendCon 2008Ivo Jansch
 
Professional PHP: an open-source alternative for enterprise development [Kort...
Professional PHP: an open-source alternative for enterprise development [Kort...Professional PHP: an open-source alternative for enterprise development [Kort...
Professional PHP: an open-source alternative for enterprise development [Kort...Combell NV
 
Enterprise PHP (php|works 2008)
Enterprise PHP (php|works 2008)Enterprise PHP (php|works 2008)
Enterprise PHP (php|works 2008)Ivo Jansch
 
Prepare for PHP Test Fest 2009
Prepare for PHP Test Fest 2009Prepare for PHP Test Fest 2009
Prepare for PHP Test Fest 2009PHPBelgium
 
Introduction into PHP5 (Jeroen van Sluijs)
Introduction into PHP5 (Jeroen van Sluijs)Introduction into PHP5 (Jeroen van Sluijs)
Introduction into PHP5 (Jeroen van Sluijs)Stefan Koopmanschap
 
Enterprise PHP (PHP London Conference 2008)
Enterprise PHP (PHP London Conference 2008)Enterprise PHP (PHP London Conference 2008)
Enterprise PHP (PHP London Conference 2008)Ivo Jansch
 
Introduction to Using PHP & MVC Frameworks
Introduction to Using PHP & MVC FrameworksIntroduction to Using PHP & MVC Frameworks
Introduction to Using PHP & MVC FrameworksGerald Krishnan
 
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)Fabien Potencier
 
Improving WordPress Performance: Xdebug and PHP profiling
Improving WordPress Performance: Xdebug and PHP profilingImproving WordPress Performance: Xdebug and PHP profiling
Improving WordPress Performance: Xdebug and PHP profilingSeravo
 
Best Practices with Zend Framework - Matthew Weier O'Phinney
Best Practices with Zend Framework - Matthew Weier O'PhinneyBest Practices with Zend Framework - Matthew Weier O'Phinney
Best Practices with Zend Framework - Matthew Weier O'Phinneydpc
 
Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)Ivo Jansch
 
Northeast PHP - High Performance PHP
Northeast PHP - High Performance PHPNortheast PHP - High Performance PHP
Northeast PHP - High Performance PHPJonathan Klein
 
Debugging with Zend Studio for Eclipse
Debugging with Zend Studio for EclipseDebugging with Zend Studio for Eclipse
Debugging with Zend Studio for EclipseOSSCube
 
Quality code in wordpress
Quality code in wordpressQuality code in wordpress
Quality code in wordpressRan Bar-Zik
 
Streamlining Your Applications with Web Frameworks
Streamlining Your Applications with Web FrameworksStreamlining Your Applications with Web Frameworks
Streamlining Your Applications with Web Frameworksguestf7bc30
 
Introduction to PHP - SDPHP
Introduction to PHP - SDPHPIntroduction to PHP - SDPHP
Introduction to PHP - SDPHPEric Johnson
 

Similar to Becoming A Php Ninja (20)

Enterprise PHP Development - ZendCon 2008
Enterprise PHP Development - ZendCon 2008Enterprise PHP Development - ZendCon 2008
Enterprise PHP Development - ZendCon 2008
 
Professional PHP: an open-source alternative for enterprise development [Kort...
Professional PHP: an open-source alternative for enterprise development [Kort...Professional PHP: an open-source alternative for enterprise development [Kort...
Professional PHP: an open-source alternative for enterprise development [Kort...
 
Api Design
Api DesignApi Design
Api Design
 
Enterprise PHP (php|works 2008)
Enterprise PHP (php|works 2008)Enterprise PHP (php|works 2008)
Enterprise PHP (php|works 2008)
 
Prepare for PHP Test Fest 2009
Prepare for PHP Test Fest 2009Prepare for PHP Test Fest 2009
Prepare for PHP Test Fest 2009
 
How To Become A Php Geek
How To Become A Php GeekHow To Become A Php Geek
How To Become A Php Geek
 
Introduction into PHP5 (Jeroen van Sluijs)
Introduction into PHP5 (Jeroen van Sluijs)Introduction into PHP5 (Jeroen van Sluijs)
Introduction into PHP5 (Jeroen van Sluijs)
 
Enterprise PHP (PHP London Conference 2008)
Enterprise PHP (PHP London Conference 2008)Enterprise PHP (PHP London Conference 2008)
Enterprise PHP (PHP London Conference 2008)
 
Test
TestTest
Test
 
Introduction to Using PHP & MVC Frameworks
Introduction to Using PHP & MVC FrameworksIntroduction to Using PHP & MVC Frameworks
Introduction to Using PHP & MVC Frameworks
 
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
symfony: An Open-Source Framework for Professionals (Dutch Php Conference 2008)
 
Improving WordPress Performance: Xdebug and PHP profiling
Improving WordPress Performance: Xdebug and PHP profilingImproving WordPress Performance: Xdebug and PHP profiling
Improving WordPress Performance: Xdebug and PHP profiling
 
Best Practices with Zend Framework - Matthew Weier O'Phinney
Best Practices with Zend Framework - Matthew Weier O'PhinneyBest Practices with Zend Framework - Matthew Weier O'Phinney
Best Practices with Zend Framework - Matthew Weier O'Phinney
 
Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)Dynamic Languages In The Enterprise (4developers march 2009)
Dynamic Languages In The Enterprise (4developers march 2009)
 
Northeast PHP - High Performance PHP
Northeast PHP - High Performance PHPNortheast PHP - High Performance PHP
Northeast PHP - High Performance PHP
 
Debugging with Zend Studio for Eclipse
Debugging with Zend Studio for EclipseDebugging with Zend Studio for Eclipse
Debugging with Zend Studio for Eclipse
 
Quality code in wordpress
Quality code in wordpressQuality code in wordpress
Quality code in wordpress
 
Streamlining Your Applications with Web Frameworks
Streamlining Your Applications with Web FrameworksStreamlining Your Applications with Web Frameworks
Streamlining Your Applications with Web Frameworks
 
Continuous feature-development
Continuous feature-developmentContinuous feature-development
Continuous feature-development
 
Introduction to PHP - SDPHP
Introduction to PHP - SDPHPIntroduction to PHP - SDPHP
Introduction to PHP - SDPHP
 

Recently uploaded

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
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
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfhans926745
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 

Recently uploaded (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
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
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 

Becoming A Php Ninja

  • 1. Becoming a PHP ninja Md. Emran Hasan emran@rightbrainsolution.com
  • 2. About me <about> Doing PHP for 5+ years Developer, consultant, manager CTO, Right Brain Solution Ltd. Previous: SWI, Pageflakes, Trippert Labs. </about>
  • 3. Introduction This presentation is about: – development practices – personal development
  • 5. 1. Coding standards • Readable code • Easy to maintain • Documentation
  • 6. <? // Method 1 if($condition) function1($a, $b, $c); if($i < 7 && $j > 8 || $k == 4) a($i); ?>
  • 7. <?php // Method 2 if ($condition) { getUser($id, $username, $key); } If (($i < 7) && (($j < 8) || ($k == 4))) { displayGraph($value); }
  • 8. • PEAR Coding Standards http://pear.php.net/manual/en/standards.php • Zend Framework Coding Standards http://framework.zend.com/manual/en/coding-standard.html • eZ Components Implementation guidelines http://www.ezcomponents.org/contributing/coding_standards
  • 9. 2. Code Commenting • Reduced code understanding time • Serves as a documentation • Answer the question: WHY??
  • 10. /** * Add number * * This function will take two integer numbers and will * return the addition result of them. * * @param int first number * @param int second number * @return int addition result */ function addNumbers($firstNum, $secondNum)
  • 11. 3. Code re-use • Re-use code across projects • Refactor every now & then • Don’t Repeat Yourself (DRY)
  • 12. 4. Code testing • Gives confidence • Unit testing in rescue • Test Driven Development (TDD)
  • 13. • PHPUnit - http://www.phpunit.de • SimpleTest - http://www.simpletest.org
  • 14. 5. PHP Framework • Forces good structure • Ready to use libraries • Solves most real-life problems 80% - 20%
  • 15. Zend Framework - http://framework.zend.com • CodeIgniter - http://www.codeigniter.com • CakePHP - http://cakephp.org/ • Symfony - http://www.symfony-project.org
  • 16. 6. Source Control (SCM) • Your own personal UNDO • Compare, rollback, track source code • Must for team collaboration
  • 17. • Subversion - http://subversion.tigris.org • Git - http://git-scm.com
  • 18. 7. PHP IDE • Increased productivity • Reduced error in code • Debugging, profiling
  • 19. • Eclipse PDT http://www.eclipse.org/pdt • Netbeans IDE http://www.netbeans.org • NuSphere PHPEd http://www.nusphere.com • Zend Studio for Eclipse http://www.zend.com/en/products/studio
  • 20. 8. Quality Code Your PHP code should – be simple – get the job done – be secure – be scalable – be maintainable
  • 22. 9. Being Communicative • Increased productivity • Reduces confusion • Builds synergy in team
  • 23. 10. Being Agile • Working iteratively and incrementally • Being responsible • Being open minded
  • 24. 11. Updating yourself • Trying new technology • Reading blogs • Get updated through RSS
  • 25. • Planet PHP – http://planet-php.net • PHPDeveloper – http://phpdeveloper.org • Sitepoint – http://sitepoint.com • PHP Classes – http://phpclasses.org
  • 26. 12. Community involvement • Starting to write blog • Participate in forum and communities • Contribute in open source projects
  • 28. Contact +880 161 PHPFOUR @phpfour phpfour@gmail.com http://www.phpfour.com/blog

Editor's Notes

  1. Naming conventionFunction name – meaningfulIndentationUse of white space and new line<number>
  2. <number>
  3. <number>
  4. <number>