Things I wish web graduates knew
Upcoming SlideShare
Loading in...5
×
 

Things I wish web graduates knew

on

  • 2,531 views

Slides from a talk I gave to local students studying PHP, about some key skills, open source, and the importance of learning to help themselves.

Slides from a talk I gave to local students studying PHP, about some key skills, open source, and the importance of learning to help themselves.

Statistics

Views

Total Views
2,531
Views on SlideShare
1,388
Embed Views
1,143

Actions

Likes
6
Downloads
35
Comments
0

3 Embeds 1,143

http://www.lornajane.net 1123
http://localhost 19
http://www.linkedin.com 1

Accessibility

Categories

Upload Details

Uploaded via as OpenOffice

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Things I wish web graduates knew Things I wish web graduates knew Presentation Transcript

    • Good Practice in PHP Or "Things I Wish New Recruits Knew"
    • About Me
      • Lorna Mitchell
      • Twitter: @lornajane
      • PHP consultant, trainer, and author
      • I live in Leeds
      • Website: http://lornajane.net
      • Book: http://sitepoint.com/books/phppro
    • Today's Outline
      • Software Development Lifecycle
      • Databases
      • Source Control
      • Documentation
      • Open Source
    • Software Lifecycles
    • Waterfall
    • Waterfall
    • Agile
      • Many different interpretations
      • Some or all of:
        • iterative
        • customer involvement
        • product is always working
        • done in bursts called "sprints"
        • spec can change (in a controlled way)
    • Databases
    • Databases
      • Not a dumping ground
      • Often your application bottleneck
      • Worth understanding
    • Tools
      • phpMyAdmin
        • http://phpmyadmin.net
      • Command Line
        • powerful
        • well-documented
    • Normalised Forms
      • Guidelines for good table design
      • 1 st Normal Form
        • no repeating groups (e.g. comma separated lists)
      • 2 nd Normal Form
        • decouples entities and links them by relationship (e.g. customer data separate from order)
      • 3 rd Normal Form <- good enough!
        • removes redundancy and dependent information
    • Indices
      • An index allows MySQL to quickly find things
      • Foreign key contstraints
      • Columns used in where clauses
    • EXPLAIN
      • MySQL command
      • Which indexes are used
      • What kind of indexes
      • Number of rows scanned
      • Great for diagnosing slow queries
    • Source Control
    • Using Source Control
      • Create a repository, add project
      • Check out project
      • Make changes
      • Update to get other changes
      • Commit changes to repo
    • svn log ------------------------------------------------------------------------ r3 | lornajane | 2010-04-25 10:32:09 +0100 (Sun, 25 Apr 2010) | 1 line adding documentation notes ------------------------------------------------------------------------ r2 | lornajane | 2010-04-22 09:07:56 +0100 (Thu, 22 Apr 2010) | 1 line outlining source control and design patterns sections ------------------------------------------------------------------------ r1 | weierophinney | 2010-03-30 17:37:27 +0100 (Tue, 30 Mar 2010) | 1 line Added readme with outline ------------------------------------------------------------------------
    • svn diff Index: README.txt =================================================================== --- README.txt (revision 3) +++ README.txt (revision 4) @@ -31,12 +35,20 @@ to share ideas to raise profile to be told you're doing it wrong! + (pulling up examples off our own blogs, if connection allows) Testing (Matthew) QA tools and CI including code analysis, mess detection, etc (Lorna - QA tools; Matthew - CI) + Static analysis + code sniffer + demo examples, find a suitable small codebase (joindin?) + mess detector + demo examples + what else? + Deployment
    • Source Control Tools
      • Subversion (svn)
        • http://subversion.apache.org/
      • Git (git)
        • http://git-scm.com/
      • Mercurial (hg)
        • http://mercurial.selenic.com/
    • Accessing Source Control
      • IDE Plugins
      • Trac ( http://trac.edgewall.org/ )
      • TortoiseSVN
        • TortoiseGit
        • TortoiseBzr
        • TortoiseHg
    • Centralised Source Control user repo user user user
    • Centralised Source Control
      • Single repo (repository)
      • Always commit to central
      • Can branch centrally
    • Distributed Source Control repo repo repo repo repo
    • Distributed Source Control
      • Many repos
      • Commit to local repo
      • Share changes between anywhere
      • No central point
    • What If I Don't Have Source Control?
      • Get some :)
      • Install subversion
      • Use a hosted solution
    • Documentation
    • API Docs
      • Documentation generated from source code itself
      • Follows code structure
        • classes
        • inheritance
        • methods
        • parameters
    • PHPDocumentor
    • PHPDocumentor
      • PHPDocumentor
        • http://www.phpdoc.org/
      • Uses reflection
      • Comments for additional information
      • Add descriptions to the documentation
    • PHPDocumentor Comments 1 < ?php 2 3 class AttendeeList { 4 private $attendees ; 5 private $observers ; 6 7 /** 8 * Add an attendee to the list 9 * 10 * @param integer $id Attendee identifier/array index 11 * @param string $name Full name of the attendee 12 * @access public 13 * @return boolean If attendee was successfully added 14 */ 15 public function addAttendee ( $id , $name ) { 16 $this -> attendees [ $id ] = $name ; 17 $this -> notify (); 18 } 19 20 }
    • Beyond API Docs
      • Tutorials
      • Installation instructions
      • Examples
      • FAQs
      • Forums
      • User-contributed
    • Today's Outline
      • Software Development Lifecycle
      • Databases
      • Source Control
      • Documentation
      • Open Source
    • Other Topics
      • System administration
      • Maintenance and bugs
      • Design patterns
    • Open Source
    • Open Source
      • Free software
        • Free as in beer
        • Free as in freedom
      • Licensing
        • BSD
        • GPL
      • Avoid reinventing the wheel
    • Open Source
      • Find excellent (free) tools
      • Build excellent (free) tools
    • The Local PHP Scene
      • LeedsPHP http://leedsphp.org
      • PHPNW http://phpnw.org.uk
      • GeekUp http://geekup.org
    • The Global PHP Scene
      • Everything happens on IRC
        • try #phpc or #phpnw for starters
      • Read http://phpdeveloper.org daily
      • Check out http://stackoverflow.com
      • Learn to help yourself!
    • Questions?