Professional Documents
Culture Documents
Applications in PHP
John Coggeshall
Introductions
• Welcome!
• About me
• CTO of Automotive
Computer Services (ACS)
• Core PHP 5 Dev
• Author, Speaker
3
History
• ACS has a single product
called a DMS (Dealer
Management System)
• Originally Built in DOS-
based Foxpro (1992)
• Migrated to Visual Foxpro
(2004)
4
History
• Software runs off of
a Samba share on a
slackware server
• Every modifies the
same “local” database
file
• Cross-location
interaction via Remote
Desktop
5
We’re Doomed!
• Besides the obvious technical limitations of
the system, our product had problems that
hold up our business:
• No data sharing
6
Our Solution..
• The solution: An internet-based DMS
• PHP / Zend Framework to the rescue!
7
We’re Saved!
• Adobe AIR / Flex to the
Rescue!
• With Flex / AIR for the user-
interface and PHP/ZF on the
backend we are able to
accomplish all of our goals
• Flex/AIR provides the user-
experience demanded by our users
• PHP / ZF provide the server-side
magic
8
Our Development Stack
• Zend Studio for Eclipse
• PHP / ZF development
9
Server Setup
• MySQL Database
• Some stored procedures for complex
manipulations
• Multi-Protocol architecture
• Supports RPC calls via “REST-ish” XML services as
well as the Adobe AMF format via the Zend_Amf
component of Zend Framework
10
Frontend Setup
• Adobe Flex and AIR runtime (duh)
• Fundamentally a PureMVC-based architecture
11
Code!
Not without problems
• Flex and AIR work pretty well with PHP,
but there are a lot of problems
• Lack of Server-push technology available on the
PHP side makes saving data pretty painful
• Have to devise your own saving mechanisms and
keep them consistent
• Lack of Server-push makes collaboration painful
across clients
13
Hardware == Painful
• As powerful as AIR is a platform, it has a
serious flaw
• NO support for hardware on any level means all of
those bar-code scanners, driver’s license scanners,
custom printers we use suddenly can’t be used
• … Okay, now we’re really doomed.
14
PHP^H^H^HJava!!
• Of all things, Java comes to the rescue!
• The Merapi project
• http://www.merapiproject.net
15
Deployment
• New Problem: Deployment
• AIR has great facilities for this
16
Final Thoughts..
• Flex/AIR is the right tool for our job
• Even though it’s NOT the right tool for our job
(yet)
• Offers a much more compelling user experience
than we could produce with JS/HTML/CSS
• Definitely not the right tool for every job
18