BADCamp 2012 -Beginner Best Practices

  • 1,025 views
Uploaded on

 

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
1,025
On Slideshare
0
From Embeds
0
Number of Embeds
4

Actions

Shares
Downloads
7
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. BADCamp 2012Beginner Best PracticesMeghan Sweet (@meghsweet)4 November, 2012
  • 2. How do you learn Drupal?
  • 3. Sometimes things are really easy.
  • 4. Sometimes things are really hard.
  • 5. Leveraging Contributed ModulesStanding on the Shoulders of Giants- Assess the project page- Read the README file-Views, admin_menu, ctools, webform,wysiwyg, panels, context.
  • 6. Where does Contributed code live?Put all contrib modules in ../sites/all/modules/OR../sites/all/modules/contribPut all custom modules in../sites/all/modules/customPut all themes in../sites/all/themes
  • 7. http://drupal.org/project/views/
  • 8. What do you need in your toolbox?HTML / CSS / Javascript / PHPA good code editorFirebug or Chrome InspectorDrupal CommunityYou can leverage a lot of skills you already have.
  • 9. Local Development EnvironmentLocal EnvironmentDrushVersion Control such as GITBasics of the command line
  • 10. Development WorkflowDevelopment Environment- Dev > Test > LiveWhere do your clients QA?Use Version control to push to production- great for rolling back changes- great for multi-developer environmentsCode vs Content- features moduleWorkflow to push to productionExclude the files directory from the repo, files are like data.
  • 11. The “Drupal Way”?
  • 12. Site Development Plan Typical Drupal Site
  • 13. A complex system that works isinvariably found to haveevolved from a simple systemthat worked...Galls Law
  • 14. Build features zoomedin, then pull back and see how it all fits together.
  • 15. Write a development planForces you to think through your architectureand implications of decisionsMakes it a lot easier to build quickly- ex: graball your modules at once, understand contentand layout dependenciesBuild, then theme90% of the way there is often enough- Don’t be afraid to talk to your clients
  • 16. Structure ContentBreak up your content into the pieces you wantcontrol over.Important in mobile theming- content firstConsider your admins and your visitors.Good content is user-centeredAdopt the cognitive frameworks of your users-ERIN KISSANE
  • 17. Feature DevelopmentIts essentially three steps, rinse and repeat.1) Build a content type2) Build a view3) Build a layout
  • 18. Skew, The Frontend Engineers Misery
  • 19. Slow Site?
  • 20. Common Client-sidePerformance Pitfalls- Cache Settings- Image Optimization- Image File Subdirectories- CSS Images- Size of pages, libraries, CSS.
  • 21. Theming!Where everything can be overridden.
  • 22. There is no "best" theme. -@rupl
  • 23. Where to start Develop a theming strategy and find a theme to match- ‘Starter’ themes- Base Themes- Responsive Theming- Click-to-Config
  • 24. Control your layout throughconfigurationPanels, Panelizer, PanopolyContextOmegaDisplay Suite
  • 25. Advancing ThemingIts all about OverridingConfiguration -> CSS -> PHP
  • 26. You can give back to the community.
  • 27. Coding Standards-Don’t Hack Core! It may seems like a good idea now, but itsnot.- Indent of 2 spaces- No trailing white space- CSS properties in alphabetical order- Comment your code, you’ll thank yourself later.- Participate in the issue queue and documentation.
  • 28. Learn MoreBooks Camps and ConsTraining IRCDocumentation Spirit of willingness, givingBlogs back and helping each otherVideosMeetups
  • 29. Thank You!@meghsweet @chapter_three