2. about me & this talk
● Since 1998 in the Internet Industry (Kelkoo,
Yahoo!, BuyVIP)
● Technology and Internet passionate
● Founder of Acilia Internet, Spanish development
company based on Madrid
This talk is about real experiences and
recommendations
3. contents
● Project plan: Before hands on starts
● Why Symfony and Doctrine
● Choosing the right partners for usability and
design
● Techniques and CMS features to evaluate
● Maintenance and final delivery
4. project plan
● Imagine the moment of delivery and plan
backwards – examine every piece
● Designate stakeholders
● Open communication channels, recurrent
follow-up
● Tests beginning the first day
Tools like Symfony helps you to
predict project timings and efforts
dramatically. The more projects you
develop, the more accurate you'll
be.
5. project plan
● Project management is people management
and organization
● Trained and experienced people performs >
x10 more
6. project success
5%
People (55%)
Communication
(40%)
40%
Other (5%)
55% Luck (0%)
7. why Symfony
● Very active development and support
● Learning curve but really good documentation
● Big Growing Community
● One of the most complete PHP Framework
● Admin generator: Rocks!
● Form framework: Rocks!
8. why Symfony
● For the final project owner: easy maintenance
and support
● Product based on good practices and design
patterns: lower risk
● For the development company: reusable
developments / development intelligence.
● For the development company: easy to
integrate new engineers to the project
9. why Doctrine
● Hard choice, we used Propel in the past
● Great documentation.
● Our perception: more activity, community
support
10. why PHP
● Used on most of the high traffic websites
(Facebook, Yahoo!, Wikipedia)
● Easy to learn, easy to use (Scripting language)
● Nifty vs. tedious languages
● #1 language on the web
● Years of experience and tools If you reach the point where PHP
is the performance bottleneck,
● Performance? congratulations: You have a
Grade A application faster than
99% webs over the Internet
11. why not Joomla or Drupal
● If the project has some complexity or somewhat
specific features, you'll problably have to
dismantle it
● Not optimal for specific data models
● Fast to implement and install. Really hard (or
impossible) to customize and maintain
● It has also a learning curve You'll face the question: Yes, but
whitehose.gov is made on
Drupal!!
Whitehouse.gov is a simple
project, with common data models
12.
13. Usability and Design
● Jobeet Chapter 2 - “The project” is great and
seems simple, but it is not that simple.
● Reaching a simple mock-up requires quite a lot
effort and needs all stakeholders input.
● You should plan this stage carefully
14. Simple search or
advanced search? Unique RSS Feed
How will the or RSS feed per
results look like? category?
How many
categories will be Who can post a
displayed? job
What are the How many results
fields needed? should we display
Is there any ad
Can we sort by? space? How do
we manage it?
15. Usability and Design
● You will have to face many confronted interest
in your client (editors want a good backend,
product developers a cool front-end with no
ads, business people a big ad space, CEOs a
cheap and good quality website...)
● UX and Design professionals are out there.
Partner with them! You will save time (and
health)
16. Usability and Design
● A great application can be seen as poor
because of a wrong graphic design
● A poor application can be seen as great with a
good graphic design
17. CMS Features
● One of the first questions is what to manage.
● Every piece can live without the “administration”
software
● The more management, the more complexity
18. CMS Models Classification
● Content (Articles, Videos, Images, Galleries...)
● Templates (Probably the most complex part)
● Users & Community (Frontpage, Backend,
Permissions)
19. Data
● Data Model
● Do we have data to import?
● Tasks – Initial load. Incremental load
● 301 redirects from old urls to new urls
(Important)
20. Backend
● Intensive use of admin generator
● Fast for models management
● Look for solutions for objects relationships
– Pop-ups
– Lightbox Extesions of sfWidgetForm Class
– JQuery plugins
21.
22. Shared Characteristics - Behaviours
● Doctrine Behaviours will help to build shared
characteristics for models
– Visible
– Commentable
– Tagable
– Navigation Related
– Attributable
– ...
23. CMS Models - Navigation
● Navigation is the central taxonomy column in
the CMS system
● Nested set – Multiple roots
● Content and Template models are related to it
24.
25.
26. CMS Models - Domains
● CMS accepting multiple sites
● Content can be asociated to multiple domains,
but must have a main domain
● Decision: Multiple categories ?
27. CMS Models - Articles
● Texts with several images (or other objects) associated
● Cover Image – Representative image
● Creation time, Publish time
● Multiple templates system
● Virtual fields vs. Real fields
● Inspired in Radius - Radiant CMS (http://radiantcms.org/) and Liquid -
macro language, similar to HTML
● YAML
28.
29. Multi-template Articles
Template (Backend) Article (Backend) Article (Frontend)
* Gets template and * Renders the
* Skeleton fo the final ask for necessary content, based on
layout. It contains the information. the template and the
HTML + tag based
template engine
+ * Generates Form
= data stored in the
backend.
syntax Widgets.
* Virtual fields -
YAML
Designers / Front-end engineers Editors
32. YAML Storage
vertical_image:
id: '190784'
quote: 'Zara to land in India in 2010'
main_text:
Text: "
Zara group is opening new stores in India,
starting with a major shop in Delhi, .....”
33. CMS Models -Images
● Elements (name, file, width, height...)
● Resize on demand (GD, Imagemagick)
● Storage
– CDN
– Custom server optimized (lighthttpd, cherokee...)
– Every server (Rsync sycronization, reverse proxy)
34. Original Image Thumbnail with
Gravity Top
Thumbnail
without Gravity
35. Template Management - Navigation
● Ability to manage and automate layouts, templates
and modules: not only a template language.
● Layouts (decorators) and templates are associated to a
navigation points
● Hierarchical Inheritance
● Backend controls template system
36.
37. Template Management - Navigation
Template (Backend) Template Configuration Page (Frontend)
(Backend)
* Renders the
* Skeleton fo the final * Gets template and ask content, based on
layout. It contains the for necessary the template and the
HTML + tag based
template engine
+ information. = data stored in the
backend.
syntax * Generates Form
Widgets.
* Virtual fields.
Designers / Front-end engineers Editors
38.
39.
40. Template Management
Template Example
<ul class="home_links">
<li>
<ul>
<snippet:eachArticle config: { name: enlace_articulo_moda }>
<li><a href="<?php echo $record->url ?>">
<?php echo $record->getTitle() ?>
</a></li>
</snippet:eachArticle>
</ul>
<p><a href="/moda"> ver todas las noticias de 'moda'</a></p>
</li>
<li>
43. Other Features and tools
● User Management and permissions (sfGuardUser)
● Comments Moderation
● Custom data models (sport standings, real state listings...)
● Sphinx search
● External Feeds
● Git
44. Infraestructure
Web
Users Internet Load Balancer
Web Server 1 Web Server 2
Multiservice Backend
Write Queries
Read Queries
Master DB Slave DB
45. Performance
$timer = sfTimerManager::getTimer('myTimer');
// Do things
● Symfony timer ...
// Stop the timer and add the elapsed time
$timer->addTime();
// Get the result (and stop the timer if not already stopped)
$elapsedTime = $timer->getElapsedTime();
● Routing cache in versions 1.2.x
47. delivery and acceptance
● Maintenance is another topic, will the final
customer/users need it.
● Identify what to maintain from the beginning
(infraestructure, templating, design...)
● Many times, you'll find yourself maintaining not
being able to leave the project! Plan
acceptance
48. Some Clients feedback
● “I expected bugs!! Where are they?” (Or where
are they in the planification?)
● “I expected a traffic drop. It is increasing since
first day!!”
● “Symfony is slow? My site is fast!!” - Many
times performance issues are not in the
framework or language (PHP) itself.