enterprise php (arteveldehs, 2010)
DESCRIPTION
Overview of PHP and common practices describing using PHP in a professional environment. This talk was given as a seminar to a group of senior graduate students (Multimedia) at the Arteveldehogeschool, Gent.TRANSCRIPT
Enterprise PHPArtevelde College, 2010
Felix De Vliegher & Michelangelo van Dam
vrijdag 19 maart 2010
Felix De Vliegher
Consultant @ Ibuildings
PHP evangelist
co-founder PHPBenelux
conference speaker
Twitter @felixdv
vrijdag 19 maart 2010
Michelangelo van Dam
PHP consultant
elephpant shepherd
co-founder PHPBenelux
conference speaker
twitter @DragonBe
vrijdag 19 maart 2010
You ?
development experience ?
PHP experience ?
PHP & OOP ?
professional development experience ?(outside Artevelde)
vrijdag 19 maart 2010
Let’s talk PHP
vrijdag 19 maart 2010
PHP & Open Source
World Wide Community
best support ever !(irc, mailing lists, forums, twitter, blogs, …)
source code available
use, change, improve, contribute
free !!!
vrijdag 19 maart 2010
PHP = sexy
vrijdag 19 maart 2010
The beginning
PHP was
for amateur sites
not ready for the heavy duty
a toy
vrijdag 19 maart 2010
Present
PHP is
for any web apps
heavy traffic/data
a solution for any web application
vrijdag 19 maart 2010
Future
PHP will be
...
vrijdag 19 maart 2010
PHP key features
built for the web
a glue solution (Java, .NET, …)
open source (cheap, customizable, …)
runs natively on major platforms(Linux, Windows, IBM i5, Sun Solaris, …)
vrijdag 19 maart 2010
Automation
Communication
E-commerce
Energy
Financial
Food
Entertainment
Government
Health care
Non-profit
Transportation
Travel & Holidays
Industries
vrijdag 19 maart 2010
PHP in daily life
vrijdag 19 maart 2010
PHP supported by
vrijdag 19 maart 2010
Frameworks
ease of development
structural architecture
loosely coupled <> full stack
DRY
maintenance friendly
extendable, modular and feature rich
vrijdag 19 maart 2010
PHP Frameworks
Zend Framework
Symfony
Code Igniter
Solar
Agavi
vrijdag 19 maart 2010
Security
protect against
SQL injections
cross-site scripting
buffer overflow exploits
session hijacking
human error (or stupidity)
vrijdag 19 maart 2010
Filter inputEscape output
vrijdag 19 maart 2010
Basic prevention
filter input, escape output
logging, monitoring and reporting
tokenize forms
expect all data to be tainted
don’t use globals
vrijdag 19 maart 2010
Performance++
scaling of PHP applications
optimization of code
using callback vs. foreach loop
db optimization vs. normalization
caching (code, components, pages, db, …)
PHP Hip Hop
vrijdag 19 maart 2010
Facebook statsMore than 400 million active users50% of our active users log on to Facebook in any given dayMore than 35 million users update their status each dayMore than 60 million status updates posted each dayMore than 3 billion photos uploaded to the site each monthMore than 5 billion pieces of content (web links, news stories, blog posts, notes, photo albums, etc.) shared each weekMore than 3.5 million events created each monthMore than 3 million active Pages on FacebookMore than 1.5 million local businesses have active Pages on FacebookMore than 20 million people become fans of Pages each dayPages have created more than 5.3 billion fans
Source: http://www.facebook.com/press/info.php?statistics
vrijdag 19 maart 2010
Netlog statsIt!s going pretty good
0
10.000.000
20.000.000
30.000.000
40.000.000
Janu
ary-
07
Febru
ary-
07
Mar
ch-0
7
April-07
May
-07
June
-07
July-0
7
Augus
t-07
Octob
er-0
7
Nov
embe
r-07
Dec
embe
r-07
Janu
ary-
08
Febru
ary-
08
Mar
ch-0
8
April-08
Monthly Unique VisitorsNorthern Europe3%Americas
10%
Western Asia16%
Eastern Europe3%
Southern Europe22%
Western Europe46%
0
50.000.000
100.000.000
150.000.000
200.000.000
Janu
ary-
07
Febru
ary-
07
Mar
ch-0
7
April-07
May
-07
June
-07
July-0
7
Augus
t-07
Octob
er-0
7
Nov
embe
r-07
Dec
embe
r-07
Janu
ary-
08
Febru
ary-
08
Mar
ch-0
8
April-08
Monthly Visits
0
1.250.000.000
2.500.000.000
3.750.000.000
5.000.000.000
Janu
ary-
07
Febru
ary-
07
Mar
ch-0
7
April-07
May
-07
June
-07
July-0
7
Augus
t-07
Octob
er-0
7
Nov
embe
r-07
Dec
embe
r-07
Janu
ary-
08
Febru
ary-
08
Mar
ch-0
8
April-08
Monthly Page Requests
Source: Netlog at Kings of Code 2008vrijdag 19 maart 2010
PHP rocks !
vrijdag 19 maart 2010
Higher Quality
design patterns
coding standards
development methodologies (agile, scrum, …)
version control (CVS, Subversion, GIT, …)
documentation
unit testing (PHPUnit, SimpleTest, PHPT)
vrijdag 19 maart 2010
Design Patterns
a solution to common coding challenges
tried and tested
specific “lingo” for developers
increases readability of code
vrijdag 19 maart 2010
Coding Standards
increase readability of code
consistent code usage by each developer
easier detection of flaws and security holes
a must for corporate/enterprise development
vrijdag 19 maart 2010
Dev Methodologies
improvement of a development job
better understanding of
project’s scope
project’s lifetime
immediate feedback
vrijdag 19 maart 2010
Version Control
keeps track of changes of the codemerges changes on same code base(when some developers change same file)multiple versions exists in branchesenables release managementrevert back in case of errorsprovides a back up
vrijdag 19 maart 2010
Documentation
in-code documentation (doc blocks)used for API documentation (PHPDocumentator)
end user documentationxml for DocBookwiki on intranet/extranet/interneta digital document as reference
vrijdag 19 maart 2010
Why test ?
behaves the code as expected ?
triggers exceptions when it should ?
are security issues tackled ?
is a reported issue a valid one ?
where am I in my project (TDD) ?
vrijdag 19 maart 2010
Testing
I pity the fool who doesn’t write tests!
vrijdag 19 maart 2010
Benefits of testing
more testing == less debugging!
applications should work as expected
actually takes less time
provides higher quality
easier to refactor and change
makes confident developers
vrijdag 19 maart 2010
Testing
vrijdag 19 maart 2010
Get Certified
Zend PHP 5 certification
Zend Framework Certification
Why:
Differentiate when looking for a job
Get listed in Zend Yellow Pages
Confirmation of a decent PHP skill set
vrijdag 19 maart 2010
A PHP career ?
NOW is the time !!!
many PHP developers wanted
in all industries
good salary and benefits
and more …
vrijdag 19 maart 2010
Seeking internship ?
come and see us after the session
vrijdag 19 maart 2010
Interesting reading
Books:
All of php|architect
Power PHP 5 programming
Advanced PHP Programming
Magazines:
php|architect magazine
vrijdag 19 maart 2010
Wanna know more ?Websites:
http://www.phpdeveloper.orghttp://devzone.zend.comhttp://planet-php.orghttp://techportal.ibuildings.com
IRC (irc.freenode.net): #phpc, ##php, #php_bnl
Training: PHP|Architect - http://www.phparch.comIbuildings - http://www.ibuildings.comZend - http://www.zend.com
vrijdag 19 maart 2010
… or come and see us
PHPB ENELUX
www.phpbenelux.eu
vrijdag 19 maart 2010
PHPBenelux
one of the largest PHP user groups
monthly meetings in BE, NL or LU
annual international PHP conference
yearly events (Bughuntday, PHPTestFest, …)
networking hub (Microsoft, IBM, Sun, …)
information center
vrijdag 19 maart 2010
Next meeting
when: Wednesday, April 28 at 19:30where: Combell offices Ghent (B)(see http://combell.com for details)what:
2 sessionsfree goodiesdrinks and talks
follow @PHPBenelux on Twitter for updates
vrijdag 19 maart 2010
CreditsFelix De Vliegher by @skoop on Flickr.comhttp://www.flickr.com/photos/skoop/4395237541/
Michelangelo van Dam and his coffee by @akrabat on Flickr.comhttp://www.flickr.com/photos/akrabat/3634184017/
Sexy elephpant by Ray Thomashttp://1.bp.blogspot.com/_FKArYkQGfrY/SZLPKamDI1I/AAAAAAAAChk/ZaHi63UP8iE/
Wallpaper by art crimes on Flickr.comhttp://www.flickr.com/photos/artcriminal/126263552/
Boston Downtown Skyscraper by ReneS on Flickr.comhttp://www.flickr.com/photos/rene-germany/28095903/
Spacestation over Rochester by Travelin’ Librarian on Flickr.comhttp://www.flickr.com/photos/travelinlibrarian/259774103/
vrijdag 19 maart 2010
Questions?
vrijdag 19 maart 2010
Thank you!
get these slides on SlideShare.comhttp://www.slideshare.net/group/phpbenelux
vrijdag 19 maart 2010