john pfeiffer
  • Home
  • Categories
  • Tags
  • Archives

drupal 6 custome theme how to create a zen subtheme part one

Note - you should only create custom themes in a test environment, leave your production website alone until you've got everything working!

  1. Download the newest version: http://drupal.org/project/zen

  2. Extract the files into a directory (e.g. tar -xzvf zen-6.x-1.1.tar.gz or winzip and extract)

  3. Upload the files using FTP (or better yet, SFTP) into the /drupal-root/sites/all/themes

  4. Upload the STARTERKIT directory that's inside your zen-6.x-1.1 folder from your pc into the /drupal-root/sites/all/themes

  5. Rename both the pc version and online STARTERKIT directory to your_subtheme_name (lowercase and underscores only)

  6. Inside both the pc version and the online STARTERKIT directory, rename the STARTERKIT.info.txt to your_subtheme_name.info

  7. On your pc, open the your_subtheme_name.info file and find and replace every "STARTERKIT" with "your_subtheme_name"

  8. inside your_subtheme_name.info find the following lines:

; The name and description of the theme used on the admin/build/themes page. name = Zen Sub-theme Starter Kit

Replace the "zen Sub-theme Starter Kit" with your_subtheme_name
  1. & 10. Do step 7 for the "template.php" and "theme-settings.php" files.

  2. Upload all 3 modified files (overwrite) to your /drupal-root/sites/all/themes/your_subtheme_name directory

  3. Using your FTP download the following files from:

    /drupal-root/sites/all/themes/zen-6.x-1.1/zen/zen

    html-elements.css, layout-fixed.css, layout-liquid.css, print.css, zen.css

  4. Upload all of the above files into your directory: /drupal-root/sites/all/themes/your_subtheme_name

    12a. If you want a fixed (ie 1024px) css layout then rename layout-fixed.css to layout.css 12b. If you want a resizable css layout then rename layout-liquid.css to layout.css

  5. As the Drupal administrator login to your site and enable your new sub theme: Administer -> Site building -> Themes

http://yourdomain.com/admin/build/themes/select (you'll probably want to set it as default)

Apparently Drupal 6 is smart enough that when you click save:

For easier theme development, the theme registry is being rebuilt on every page request. It is extremely important to turn off this feature on production websites.


You may have to:

run cron manually (or you should be) so that the new options appear on the Drupal Menus.

Reload after you save the new theme as enabled & default


  • « Win CE c read file c windows main
  • drupal 6 custom theme how to create a zen subtheme part two advanced »

Published

Feb 22, 2010

Category

drupal

~312 words

Tags

  • 6 13
  • a 23
  • create 14
  • custome 1
  • drupal 43
  • how 18
  • one 1
  • part 2
  • subtheme 2
  • theme 7
  • to 63
  • zen 4