1 / 22

Dr BigNo Z e or: How I Learned to Stop Worrying and Love the SYD-PHPUG

BigNo Z ePick(et)s By BigNo Z e. Dr BigNo Z e or: How I Learned to Stop Worrying and Love the SYD-PHPUG. BigNo Z e is / I am. An ImPHPostor – ie. I have never been employed to write PHP I work alone ......

natane
Download Presentation

Dr BigNo Z e or: How I Learned to Stop Worrying and Love the SYD-PHPUG

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. BigNoZePick(et)s By BigNoZe Dr BigNoZe or:How I Learned to Stop Worryingand Love the SYD-PHPUG

  2. BigNoZe is / I am • An ImPHPostor – ie. I have never been employed to write PHP • I work alone ...... • BUT I am not a SPHPY – I attend PHP-UG cause I expect to mentor/work in a PHP project one day • And I have written some PHP systems – one of which started during the Great War of 1997

  3. The Super League War • 1997 Super League goes to war – and VP Porker says “It's too much to try and run the tipping comp this year with pen and paper! Two draws – all sorts of teams and dates??”

  4. The BigNoZe Team steps up to the plate • We designed and wrote a Nix based Footy Tipping system in Dataflex

  5. An NRL/Super League Round • +----------------------------+--------   Home ----------------- Away ---------+ | Punter*: STEVEJ            |   X  Manly            vs   St George           | | Sport *: RUGBY LEAGUE      |   X  Western Subs     vs   Sydney City         | | Round *: 16                |   X  Newcastle        vs   North Sydney        | | Date   : 13/06/97          |   X  ADELAIDE         vs   LEEDS               | | Journal:    360            |      CASTLEFORD       vs   HUNTER          X   | | Posted :                   |   X  NTH QUEENSLAND   vs   OLDHAM              | |                            |      BRADFORD         vs   AUCKLAND        X   | |                            |   X  CANTERBURY       vs   HALIFAX             | |                            |   X  CANBERRA         vs   LONDON              | |                            |   X  BRISBANE         vs   WIGAN               | |                            |      WARRINGTON       vs   PENRITH         X   | |                            |      SHEFFIELD        vs   PERTH           X   | |                            |      ST HELENS        vs   CRONULLA        X   | |                            |                       vs                       | |                            |                       vs                       | |                            |                       vs                       | |                            |                       vs                       | |                            |                       vs                       | |                            |                       vs                       | |                            |                       vs                       | |                            |                                                | +- F9 to Create Punters Forms+----------------------------------- F3 to Save -+

  6. Tipsters are Tabulated • +-----------------------------------------------------------------------------+ | Punter        Rounds -->   1 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | |                                                                             | | BRIAN                  7   7 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | SIMON                  7   7 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | TONY                   7   7 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ANNE                   3   3 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | MERAL                  3   3 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | PAUL                   3   3 ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | | ____________________ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___ ___    | +------------------------Do you want a hard copy ???-N------------------------+ 

  7. For fun and education we rewrote the system in • VB6 – using Distributed COM for the office • ASP – for the web when people left the office • PHP – for when we realised ASP (and Windoze in general) sucked and Linux rules.

  8. The original PHP BigNoZePicks • Was pretty awful because it was basically ASP with a '$' sign prepended to the variable names • There were no functions – no separation of HTML from code etc etc etc. • There were some include files for screen drawing etc. • I abstracted out a few lines of code and wrote some functions but essentially thought ”I should rewrite this one day – 2000? Last used 2002 Soccer World Cup”

  9. >> to 2008 Australia Day – Social Cricket Match • Tikal

  10. What are those guys doing? • I ask “What are those guys doing?” • VP says “They're scoring” • I say “Where's the laptop” • He says “I think it's all done on paper” • I go “Really? Why?” • Everyone just looks at me like I am stupid. They say nothing. Boy did I feel stupid!

  11. BigNoZePick(et)s is Born • So I determined then and there that no Australian cricketer need live without a wagonwheel by 2010 • I also determine this is a chance to pull together all the bits and pieces I have gleaned from the SYD PHP-UG over all those years. • A new, clean project! A living document ? An education resource?

  12. My Education/Honour Role • There's a copy of the code here • www.bignozepicks.com Downloads • I started with ADO-DB – I ditched it for PDO thankyou Kevin – see • /includes/dbsetup.inc.php • /includes/competition.oop.php • /includes/tipster.oop.php

  13. SPL - Iterators • Calls to the file system thankyou Kevin – SPL/Directory Iterator • /includes/listdir.inc.php

  14. Internationalisation • Remember the Milk presentation recommended to plan for Internationalisation and Scalability no matter what the project • Smarty templates provides a simple international option – come on PHP6? • See /smarty.tpl/configs/*.conf • PHP handles time zones – but I think I do this at the user experience with a chunk of Javascript.

  15. Emails and PDF • Thankyou to Brent who presented • phpMailer • FPDF • see selections.php for both of these

  16. Security • The GeekGuys presentation – I tried to remember the simple stuff • Fingerprint Session variables • see /includes/config.php and logout.php • Be wary of filename extensions • Use a honey pot to stop robot logins/posting • see index.php and form_token • Hoover all $_POST /whatever variables • see /includes/hoover.oop.inc • Encrypt passwords

  17. Smarty Templates • I had already been using them a bit but Geoffs presentation gave me some extra insights. Not for everyone apparently. BigNoZePick(et)s is Smarty gone a bit crazy. • start at /smarty.tpl/templates/main.classic.tpl

  18. Documentation • Thankyou Dean and TimphpDocumentor • I used this to create both the PHP documentation and the HELP screens via the DocBook format

  19. Other Bits and Pieces • I use phpThumb to handle images http://phpthumb.sourceforge.net/ • I use a backup routine from http://www.oldguy.us/ • I currently support MySQL and SQLite thanks to PDO. • Demo databases are generated from live data via masking User information see backuppicks.php

  20. Project Stuff • Code repository is Subversion - thankyou Rich • Project Tracking Management is Trac – thankyou Rich

  21. Outstanding ? • Session handling via MySQL - James • PHPUnit for regression testing – thankyou Sebastian • Phar(JAR) release with SQLite – thankyou Tim. • Move code repository to Bazaar – thankyou James • Finish and hand off the project to Google or Yahoo – watch for the BigNoZePick(et)s media kit next PHP meeting – thankyou Steve

  22. Quick Demo? Fin!Any Questions?

More Related