SlideShare a Scribd company logo
1 of 3
BUILD A THEME WITH ZEN
----------------------

The base Zen theme is designed to be easily extended by its sub-themes. You
shouldn't modify any of the CSS or PHP files in the zen/ folder; but instead you
should create a sub-theme of zen which is located in a folder outside of the
root zen/ folder. The examples below assume zen and your sub-theme will be
installed in sites/all/themes/, but any valid theme directory is acceptable
(read the sites/default/default.settings.php for more info.)

  Why? To learn why you shouldn't modify any of the files in the zen/ folder,
  see http://drupal.org/node/245802


*** IMPORTANT NOTE ***
*
* In Drupal 7, the theme system caches which template files and which theme
* functions should be called. This means that if you add a new theme,
* preprocess or process function to your template.php file or add a new template
* (.tpl.php) file to your sub-theme, you will need to rebuild the "theme
* registry." See http://drupal.org/node/173880#theme-registry
*
* Drupal 7 also stores a cache of the data in .info files. If you modify any
* lines in your sub-theme's .info file, you MUST refresh Drupal 7's cache by
* simply visiting the Appearance page at admin/appearance.
*


 1. Setup the location for your new sub-theme.

    Copy the STARTERKIT folder out of the zen/ folder and rename it to be your
    new sub-theme. IMPORTANT: The name of your sub-theme must start with an
    alphabetic character and can only contain lowercase letters, numbers and
    underscores.

    For example, copy the sites/all/themes/zen/STARTERKIT folder and rename it
    as sites/all/themes/foo.

      Why? Each theme should reside in its own folder. To make it easier to
      upgrade Zen, sub-themes should reside in a folder separate from the base
      theme.

 2. Setup the basic information for your sub-theme.

    In your new sub-theme folder, rename the STARTERKIT.info.txt file to include
    the name of your new sub-theme and remove the ".txt" extension. Then edit
    the .info file by editing the name and description field.

    For example, rename the foo/STARTERKIT.info file to foo/foo.info. Edit the
    foo.info file and change "name = Zen Sub-theme Starter Kit" to "name = Foo"
    and "description = Read..." to "description = A Zen sub-theme".

      Why? The .info file describes the basic things about your theme: its
      name, description, features, template regions, CSS files, and JavaScript
      files. See the Drupal 7 Theme Guide for more info:
      http://drupal.org/node/171205

    Then, visit your site's Appearance page at admin/appearance to refresh
    Drupal 7's cache of .info file data.
3. Choose your preferred page layout method or grid system.

   By default your new sub-theme is using a fixed-width layout. If you want a
   liquid layout for your theme, delete the unneeded layout-fixed.css and
   layout-fixed-rtl.css files and edit your sub-theme's .info file and replace
   the reference to layout-fixed.css with layout-liquid.css.

   For example, edit foo/foo.info and change this line:
     stylesheets[all][]   = css/layout-fixed.css
   to:
     stylesheets[all][]   = css/layout-liquid.css

     Why? The "stylesheets" lines in your .info file describe the media type
     and path to the CSS file you want to include. The format for these lines
     is: stylesheets[MEDIA][] = path/to/file.css

   Alternatively, if you are more familiar with a different CSS layout method,
   such as Blueprint or 960.gs, you can replace the "css/layout-fixed.css" line
   in your .info file with a line pointing at your choice of layout CSS file.

   Then, visit your site's Appearance page at admin/appearance to refresh
   Drupal 7's cache of .info file data.

4. Edit your sub-theme to use the proper function names.

   Edit the template.php and theme-settings.php files in your sub-theme's
   folder; replace ALL occurrences of "STARTERKIT" with the name of your
   sub-theme.

   For example, edit foo/template.php and foo/theme-settings.php and replace
   every occurrence of "STARTERKIT" with "foo".

   It is recommended to use a text editing application with search and
   "replace all" functionality.

5. Set your website's default theme.

   Log in as an administrator on your Drupal site, go to the Appearance page at
   admin/appearance and click the "Enable and set default" link next to your
   new sub-theme.


Optional steps:

6. Modify the markup in Zen core's template files.

   If you decide you want to modify any of the .tpl.php template files in the
   zen folder, copy them to your sub-theme's folder before making any changes.
   And then rebuild the theme registry.

   For example, copy zen/templates/page.tpl.php to foo/templates/page.tpl.php.

7. Modify the markup in Drupal's search form.

   Copy the search-block-form.tpl.php template file from the modules/search/
   folder and place it in your sub-theme's template folder. And then rebuild
   the theme registry.
You can find a full list of Drupal templates that you can override in the
  templates/README.txt file or http://drupal.org/node/190815

    Why? In Drupal 7 theming, if you want to modify a template included by a
    module, you should copy the template file from the module's directory to
    your sub-theme's template directory and then rebuild the theme registry.
    See the Drupal 7 Theme Guide for more info: http://drupal.org/node/173880

8. Further extend your sub-theme.

  Discover further ways to extend your sub-theme by reading Zen's
  documentation online at:
    http://drupal.org/node/193318
  and Drupal 7's Theme Guide online at:
    http://drupal.org/theme-guide

More Related Content

Viewers also liked

How to Manage Cloud Based Computing Products #pcdub
How to Manage Cloud Based Computing Products #pcdubHow to Manage Cloud Based Computing Products #pcdub
How to Manage Cloud Based Computing Products #pcdubProduct Camp Dublin
 
East Gobi Slide Show 2011
East Gobi Slide Show 2011East Gobi Slide Show 2011
East Gobi Slide Show 2011joyinmongolia
 
Divórcio e novo casamento revista ultimato
Divórcio e novo casamento revista ultimatoDivórcio e novo casamento revista ultimato
Divórcio e novo casamento revista ultimatoLUÍS CLÁUDIO REOLIVE
 
Sotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média global
Sotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média globalSotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média global
Sotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média globalMarc Bourhis
 
Do more with LESS!
Do more with LESS!Do more with LESS!
Do more with LESS!Neven Falica
 
Giới thiệu về mô hình đối thoại World Cafe
Giới thiệu về mô hình đối thoại World Cafe Giới thiệu về mô hình đối thoại World Cafe
Giới thiệu về mô hình đối thoại World Cafe Nguyen Tuan Anh
 

Viewers also liked (9)

Happy Valentine 2012
Happy Valentine 2012Happy Valentine 2012
Happy Valentine 2012
 
How to Manage Cloud Based Computing Products #pcdub
How to Manage Cloud Based Computing Products #pcdubHow to Manage Cloud Based Computing Products #pcdub
How to Manage Cloud Based Computing Products #pcdub
 
Gunnar vingren e daniel berg
Gunnar vingren e daniel bergGunnar vingren e daniel berg
Gunnar vingren e daniel berg
 
6.chinh sachtghd
6.chinh sachtghd6.chinh sachtghd
6.chinh sachtghd
 
East Gobi Slide Show 2011
East Gobi Slide Show 2011East Gobi Slide Show 2011
East Gobi Slide Show 2011
 
Divórcio e novo casamento revista ultimato
Divórcio e novo casamento revista ultimatoDivórcio e novo casamento revista ultimato
Divórcio e novo casamento revista ultimato
 
Sotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média global
Sotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média globalSotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média global
Sotrycode Grand Ouest 1er juillet - La Réalité Virtuelle, un média global
 
Do more with LESS!
Do more with LESS!Do more with LESS!
Do more with LESS!
 
Giới thiệu về mô hình đối thoại World Cafe
Giới thiệu về mô hình đối thoại World Cafe Giới thiệu về mô hình đối thoại World Cafe
Giới thiệu về mô hình đối thoại World Cafe
 

Similar to Readme

Drupal 7 theme by ayushi infotech
Drupal 7 theme by ayushi infotechDrupal 7 theme by ayushi infotech
Drupal 7 theme by ayushi infotechMandakini Kumari
 
Z04 etano template_basics
Z04 etano template_basicsZ04 etano template_basics
Z04 etano template_basicsDaouni Monsite
 
7 Theming in Drupal
7 Theming in Drupal7 Theming in Drupal
7 Theming in DrupalWingston
 
Designing for magento
Designing for magentoDesigning for magento
Designing for magentohainutemicute
 
Creating and Theming Custom Content Types
Creating and Theming Custom Content TypesCreating and Theming Custom Content Types
Creating and Theming Custom Content Typesheatherrumd
 
Converting (X)HTML/CSS template to Drupal 7 Theme
Converting (X)HTML/CSS template to Drupal 7 ThemeConverting (X)HTML/CSS template to Drupal 7 Theme
Converting (X)HTML/CSS template to Drupal 7 ThemeAdolfo Nasol
 
Theming tips and tricks
Theming tips and tricksTheming tips and tricks
Theming tips and tricksaaroncouch
 
WortdPress Child themes: Why and How
WortdPress Child themes: Why and HowWortdPress Child themes: Why and How
WortdPress Child themes: Why and HowPaul Bearne
 
Drupal 7 install with modules and themes
Drupal 7 install with modules and themesDrupal 7 install with modules and themes
Drupal 7 install with modules and themesGeshan Manandhar
 
Child Themes (WordCamp Dublin 2017) with notes
Child Themes (WordCamp Dublin 2017) with notesChild Themes (WordCamp Dublin 2017) with notes
Child Themes (WordCamp Dublin 2017) with notesDamien Carbery
 
Creating and Theming Custom Content Types
Creating and Theming Custom Content TypesCreating and Theming Custom Content Types
Creating and Theming Custom Content Typesheatherrumd
 
SynapseIndia drupal presentation on drupal best practices
SynapseIndia drupal  presentation on drupal best practicesSynapseIndia drupal  presentation on drupal best practices
SynapseIndia drupal presentation on drupal best practicesSynapseindiappsdevelopment
 
Overview on WordPress theme file structure and working functionality
Overview on WordPress theme file structure and working functionality Overview on WordPress theme file structure and working functionality
Overview on WordPress theme file structure and working functionality Rakesh Kushwaha
 
Customizing WordPress Themes
Customizing WordPress ThemesCustomizing WordPress Themes
Customizing WordPress ThemesLaura Hartwig
 

Similar to Readme (20)

Drupal 7 theme by ayushi infotech
Drupal 7 theme by ayushi infotechDrupal 7 theme by ayushi infotech
Drupal 7 theme by ayushi infotech
 
Drupal theme development
Drupal theme developmentDrupal theme development
Drupal theme development
 
Drupal Theme Development
Drupal Theme DevelopmentDrupal Theme Development
Drupal Theme Development
 
Z04 etano template_basics
Z04 etano template_basicsZ04 etano template_basics
Z04 etano template_basics
 
7 Theming in Drupal
7 Theming in Drupal7 Theming in Drupal
7 Theming in Drupal
 
Designing for magento
Designing for magentoDesigning for magento
Designing for magento
 
Creating and Theming Custom Content Types
Creating and Theming Custom Content TypesCreating and Theming Custom Content Types
Creating and Theming Custom Content Types
 
Converting (X)HTML/CSS template to Drupal 7 Theme
Converting (X)HTML/CSS template to Drupal 7 ThemeConverting (X)HTML/CSS template to Drupal 7 Theme
Converting (X)HTML/CSS template to Drupal 7 Theme
 
Theming tips and tricks
Theming tips and tricksTheming tips and tricks
Theming tips and tricks
 
WortdPress Child themes: Why and How
WortdPress Child themes: Why and HowWortdPress Child themes: Why and How
WortdPress Child themes: Why and How
 
Drupal 7 install with modules and themes
Drupal 7 install with modules and themesDrupal 7 install with modules and themes
Drupal 7 install with modules and themes
 
Drupal
DrupalDrupal
Drupal
 
Drupal theming
Drupal themingDrupal theming
Drupal theming
 
Child Themes (WordCamp Dublin 2017) with notes
Child Themes (WordCamp Dublin 2017) with notesChild Themes (WordCamp Dublin 2017) with notes
Child Themes (WordCamp Dublin 2017) with notes
 
puissance-2roue
puissance-2rouepuissance-2roue
puissance-2roue
 
Creating and Theming Custom Content Types
Creating and Theming Custom Content TypesCreating and Theming Custom Content Types
Creating and Theming Custom Content Types
 
SynapseIndia drupal presentation on drupal best practices
SynapseIndia drupal  presentation on drupal best practicesSynapseIndia drupal  presentation on drupal best practices
SynapseIndia drupal presentation on drupal best practices
 
Overview on WordPress theme file structure and working functionality
Overview on WordPress theme file structure and working functionality Overview on WordPress theme file structure and working functionality
Overview on WordPress theme file structure and working functionality
 
Customizing WordPress Themes
Customizing WordPress ThemesCustomizing WordPress Themes
Customizing WordPress Themes
 
Drupal theming
Drupal themingDrupal theming
Drupal theming
 

Recently uploaded

08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 

Recently uploaded (20)

08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 

Readme

  • 1. BUILD A THEME WITH ZEN ---------------------- The base Zen theme is designed to be easily extended by its sub-themes. You shouldn't modify any of the CSS or PHP files in the zen/ folder; but instead you should create a sub-theme of zen which is located in a folder outside of the root zen/ folder. The examples below assume zen and your sub-theme will be installed in sites/all/themes/, but any valid theme directory is acceptable (read the sites/default/default.settings.php for more info.) Why? To learn why you shouldn't modify any of the files in the zen/ folder, see http://drupal.org/node/245802 *** IMPORTANT NOTE *** * * In Drupal 7, the theme system caches which template files and which theme * functions should be called. This means that if you add a new theme, * preprocess or process function to your template.php file or add a new template * (.tpl.php) file to your sub-theme, you will need to rebuild the "theme * registry." See http://drupal.org/node/173880#theme-registry * * Drupal 7 also stores a cache of the data in .info files. If you modify any * lines in your sub-theme's .info file, you MUST refresh Drupal 7's cache by * simply visiting the Appearance page at admin/appearance. * 1. Setup the location for your new sub-theme. Copy the STARTERKIT folder out of the zen/ folder and rename it to be your new sub-theme. IMPORTANT: The name of your sub-theme must start with an alphabetic character and can only contain lowercase letters, numbers and underscores. For example, copy the sites/all/themes/zen/STARTERKIT folder and rename it as sites/all/themes/foo. Why? Each theme should reside in its own folder. To make it easier to upgrade Zen, sub-themes should reside in a folder separate from the base theme. 2. Setup the basic information for your sub-theme. In your new sub-theme folder, rename the STARTERKIT.info.txt file to include the name of your new sub-theme and remove the ".txt" extension. Then edit the .info file by editing the name and description field. For example, rename the foo/STARTERKIT.info file to foo/foo.info. Edit the foo.info file and change "name = Zen Sub-theme Starter Kit" to "name = Foo" and "description = Read..." to "description = A Zen sub-theme". Why? The .info file describes the basic things about your theme: its name, description, features, template regions, CSS files, and JavaScript files. See the Drupal 7 Theme Guide for more info: http://drupal.org/node/171205 Then, visit your site's Appearance page at admin/appearance to refresh Drupal 7's cache of .info file data.
  • 2. 3. Choose your preferred page layout method or grid system. By default your new sub-theme is using a fixed-width layout. If you want a liquid layout for your theme, delete the unneeded layout-fixed.css and layout-fixed-rtl.css files and edit your sub-theme's .info file and replace the reference to layout-fixed.css with layout-liquid.css. For example, edit foo/foo.info and change this line: stylesheets[all][] = css/layout-fixed.css to: stylesheets[all][] = css/layout-liquid.css Why? The "stylesheets" lines in your .info file describe the media type and path to the CSS file you want to include. The format for these lines is: stylesheets[MEDIA][] = path/to/file.css Alternatively, if you are more familiar with a different CSS layout method, such as Blueprint or 960.gs, you can replace the "css/layout-fixed.css" line in your .info file with a line pointing at your choice of layout CSS file. Then, visit your site's Appearance page at admin/appearance to refresh Drupal 7's cache of .info file data. 4. Edit your sub-theme to use the proper function names. Edit the template.php and theme-settings.php files in your sub-theme's folder; replace ALL occurrences of "STARTERKIT" with the name of your sub-theme. For example, edit foo/template.php and foo/theme-settings.php and replace every occurrence of "STARTERKIT" with "foo". It is recommended to use a text editing application with search and "replace all" functionality. 5. Set your website's default theme. Log in as an administrator on your Drupal site, go to the Appearance page at admin/appearance and click the "Enable and set default" link next to your new sub-theme. Optional steps: 6. Modify the markup in Zen core's template files. If you decide you want to modify any of the .tpl.php template files in the zen folder, copy them to your sub-theme's folder before making any changes. And then rebuild the theme registry. For example, copy zen/templates/page.tpl.php to foo/templates/page.tpl.php. 7. Modify the markup in Drupal's search form. Copy the search-block-form.tpl.php template file from the modules/search/ folder and place it in your sub-theme's template folder. And then rebuild the theme registry.
  • 3. You can find a full list of Drupal templates that you can override in the templates/README.txt file or http://drupal.org/node/190815 Why? In Drupal 7 theming, if you want to modify a template included by a module, you should copy the template file from the module's directory to your sub-theme's template directory and then rebuild the theme registry. See the Drupal 7 Theme Guide for more info: http://drupal.org/node/173880 8. Further extend your sub-theme. Discover further ways to extend your sub-theme by reading Zen's documentation online at: http://drupal.org/node/193318 and Drupal 7's Theme Guide online at: http://drupal.org/theme-guide