Filters - Modifying Variables In Twig Templates

Filters in Twig can be used to modify variables. Filters are separated from the variable by a pipe symbol (|) and may have optional arguments in parentheses. Multiple filters can be chained. The output of one filter is applied to the next.

Example: {{ ponies|safe_join(", ")|lower}}

The list of filters that can be used in Twig templates for Drupal consists of all the filters in the Twig engine as well as some Drupal specific filters.

Twig Filters

List of Twig filters.

Migrate Bootstrap subthemes from 2.x to 3.0

This space is reserved for theme users to share any tips that may assist others in migrating their Bootstrap subthemes from 7.x-2.x to 7.x-3.0. Consider it a Bootstrap theme supplement to the Bootstrap 3 Migration Guide. If you haven't done much to override Bootstrap theme's templates or CSS, you probably won't need this.

Theming OpenAid

OpenAid 1.0

The OpenAid distro comes with the OpenAid theme, which integrates with the Color module and is responsive out of the box.

To customize the theme for your site's needs, it is suggested that you create a child theme based off of OpenAid.

The theme's settings and color picker are located at /admin/appearance/settings/openaid

[ARCHIVED] Bootstrap sub-theming "how to"

The documentation for the Drupal Bootstrap base theme has moved to:

The documentation below is only for the 7.x-3.0 release and is considered outdated and possibly inaccurate.


Below are instructions on how to create a Bootstrap sub-theme. There are many different variations on how to accomplish this, but this will focus on primarily the two most common: using local LESS pre-processing of the source Bootstrap framework and using the built-in CDN.


Conditional Requirements for Method 1: Bootstrap Source Files

Unsupported Modules

The following modules are not supported nor recommended for use as they conflict with these documentation methods. If they are installed, use at your own risk. Issues created regarding these modules will be closed as "won't fix":

Creating a ZURB Foundation Sub-theme

Creating a sub-theme

It is imperative that you create a sub-theme to allow Zurb Foundation to apply any updates to your theme.

If you haven't already, please visit the Community documentation page regarding creating a subtheme.

There are two ways of creating a subtheme: drush and manually. We highly recommend the drush route as it's easy, quick and avoids errors.

Below, you'll find Zurb Foundation specific directions on how to create a sub-theme.

Creating a sub-theme with Drush

Creating a sub-theme with Drush can be done by executing the following command:

drush fst [name] [machine_name !OPTIONAL] [description !OPTIONAL]

Manually Creating a sub-theme for Zurb Foundation

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

Copy the STARTER folder out of the zurb_foundation/ 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

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

Why? Each theme should reside in its own folder. To make it easier to


Subscribe with RSS Subscribe to RSS - Drupal theming