Intro to Theme Development Ryan Price, Michael Anello www.DrupalEasy.com
Who are you? Designers? Developers? Site Builders? Content Administrators? Themers.
Content vs. Presentation Static HTML vs. Server-Side Includes vs. Database-Driven Sites vs. Themable Data-Driven Sites
Content vs. Presentation Easy Theme Switching in Drupal (example)
Anatomy of a Drupal Themer Graphic Designer Javascript + PHP Coder $$$ Front-end Developer
The best designers and themers see the BIG picture. IMHO User Experience (UX)
macromates.com TextMate “The Missing Editor for Mac OSX ” “Find in Project” saves my life daily See also: Smultron, KOD, TextWrangler, Coda  Espresso
notepad-plus-plus.org Notepad++ “Notepad replacement... to offer a greener environment ” Also: Crimson, e-texteditor, UltraEdit, InType, ConTEXT,   Visual Web Developer Express
Image Editor Pixelmator.com (mac)
Aviary.com (online)
GetDrawIt.com (mac)
The GIMP Firefox Extensions Firebug
ColorZilla
MeasureIt
Web Developer Toolbar A Themer's Toolbox
CSS Editor macrabbit.com – CSSEdit (mac)
westciv.com – StyleMaster (windows) FTP FileZilla – sourceforge.net
Transmit – panic.com (mac) SSH PuTTY.org (windows) Tools wafflesoftware.com - Hex Color Picker (mac)
Pixie Color Picker (windows) A Themer's Toolbox
CSS Layout
Styling
Colors
Behaviors – CSS3
Do Web Pages have to look the same in every browser? No. http://dowebsitesneedtolookexactlythesameineverybrowser.com
HTML vs. XHTML vs. HTML5 HTML5 Backwards-compatible
New layout elements (“semantic”) Section, Navigation, Header New form elements Email, Search, etc. Scripts for Legacy Browsers (IE)
DrupalCon Session - HTML5 Tuesday,1:45pm, Trellon Room
PHP (for themers) <?php print $var; ?>
if ( isset ($var)): … endif;
if (! empty ($var)): … endif;
http://drupal.geek.nz/blog/tplphps-are-not-templates
Copy/Paste PHP <?php if ($page[ 'highlight' ]): ?> <div id=&quot;highlight&quot;> <?php  print render ($page[ 'highlight' ]); ?> </div> <?php endif; ?>
What do you need to know? HTML CSS <?php  print  $content; ?> jQuery setting up a development environment version control - git a little more PHP?
Best Practice Theme Folder sites/all/themes/ drupalcon/ css/ style.css drupalcon.info images/ image.png scripts/ drupalcon.js template.php templates/ node.tpl.php
Breaking down a Drupal site HTML Page Region Node Fields Block Views Menu Panels Forms User
Template Nesting
Drupal 7 Theming Template-driven (.tpl.php) HTML  –  open <HTML> and <HEAD>
Page   –  Regions, Layout, Special Variables
site_name, logo, main_menu, tabs
Region  –  Blocks, including Main Content
Block  – almost everything
Node   – on node pages, views
Field  – markup for each field Clear the theme registry (cache)!
Template File Naming page.tpl.php page--front.tpl.php

Drupal Theme Development - DrupalCon Chicago 2011