Creating a subtheme is the way to go if you need more advanced custom styling and templating for your DXPR Drupal websites! It's as easy as subtheming any other theme, follow these easy steps!

Use the command line to generate a sub-theme

  1. Open a terminal window
  2. cd into the dxpr_theme folder. This folder should be in docroot/themes/contrib/dxpr_theme
  3. Make sure the scripts are executable on your machine with the following command:
    chmod +x scripts/*
  4. Run the sub-theme command:
    ./scripts/create_subtheme.sh
  5. Follow the instructions from the script

If you made it until here you now have a custom theme that inherits all CSS and theme settings from DXPR theme. If you enable your custom theme and visit its theme settings form you can customize the look and feel of your new custom theme. 


Adding custom CSS and Templates

  1. We provided an example CSS file in custom_theme/css/dxpr_theme_subtheme.css that is loaded globally on your website. 
  2. If you wish to add more CSS files to your theme, or to add Javascript files, follow Drupal's theming documentation about CSS and JS assets.
  3. By default your custom CSS files will not be processed by the color module. If you want your CSS files to be modified when changing the color scheme in the theme settings form, you have to add a path to the file in the 'css' array near the bottom of custom_theme/color/color.inc. For more details about how the Color module works see the color module integration documentation.
  4. When creating custom template files, please be aware that you are subtheming both DXPR theme and Bootstrap theme, because DXPR theme is a subtheme of the Bootstrap basetheme.