Here you will learn about Zentropy components.
This page is under construction.
Advanced Drush Integration
If you use Drush 5.0-rc2 or newer you can download and install optional components using Drush:
drush zdl --help will list the available components.
drush zdl "theme_machine_name" "component_name" will download and automagically install the component into your subtheme.
You can also optionally specify one or more components to be automatically added and installed in new subthemes:
drush zns "Theme Name" "theme_machine_name" --with-component1 --with-component2 etc...
Components are frequently-used 3rd party libraries that can't be distributed with Zentropy due to licensing restrictions. They are pre-integrated with Zentropy and can be easy enabled/disabled with one line.
- jQuery Easing
- jQuery HoverIntent
- jQuery bgiframe
- More coming soon (file issues to get your suggestions in!)
*Important: We include the development version of Modernizr. Please download a custom build before putting your website in production.
Disabling an enabled component
drush zdis "theme_machine_name" "component name"
Re-enabling a disabled component (just re-run the command to download it!)
drush zdl "theme_machine_name" "component_name"
Follow these steps in order to manually install a component:
- Pick a component
zentropy.drush.incin Zentropy's main folder
- Find the function
- Locate the array key with the same name as the component you want to install and copy it into your favorite text editor
- Each key in the nested array contains important information regarding the component
- Download the component manually, you can find the link in the "url" key
- The directory where you should extract it is the value of the "dir" key. NOTE: It has to be under your libraries directory:
- Finally, copy the value of the "replace" key
- Now open your Subtheme's
- Inside the function
SUBTHEME_preprocess_html(), look for
- Look for a commented code block with your component's name
- Paste the "replace" text over the commented code block
Example: Manually enabling the Modernizr component:
'bgiframe' => array(
'name' => 'jQuery bgiframe',
'url' => 'https://github.com/downloads/brandonaaron/bgiframe/bgiframe_2.1.2.zip',
'type' => 'get',
'dir' => 'jquery.bgiframe',
'replace' => "drupal_add_js('sites/all/libraries/jquery.bgiframe/jquery.bgiframe.js', array('scope' => 'header', 'group' => JS_LIBRARY, 'every_page' => TRUE));",
'instructions' => "Check out http://brandonaaron.net/code/bgiframe/docs for instructions on how to use bgiframe.",
- Download the plugin from:
- Extract it to
#bgiframe#in your Subtheme's template.php
- Replace it with
drupal_add_js('sites/all/libraries/jquery.bgiframe/jquery.bgiframe.js', array('scope' => 'header', 'group' => JS_LIBRARY, 'every_page' => TRUE));