Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). Varbase Media Header 9.2.1 Minor update available for module varbase_media_header (9.2.1). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

Page Specific Class

2,615 sites Security covered
View on drupal.org

This module allows you to add custom CSS classes to the `<body>` tag of specific pages based on their URL paths. This can be useful for applying unique styling to different sections of your website.

Ability to add HTML attribute classes for CSS styling to the <body> tag based on path conditions. Specify body classes for pages by using their paths.

Features

  • Add different classes to the body tag of any page.
  • Support all Pages which can be created via Node, Views or Custom Route

How to use?
============
To learn more about the project and how to install and use it check out the README.txt. Feel free to report issues and by helping on the documentation pages.

Video tutorial = Check on Youtube

Similar projects with different attempts:

  1. Custom Body Class (very similar)
  2. Body node ID class
  3. Extra body classes

Activity

Total releases
3
First release
May 2025
Latest release
1 year ago
Releases (12 mo)
0 ▼ from 3
Maintenance
Dormant

Release Timeline

Releases

Version Type Release date
2.0.10 Stable May 29, 2025
2.0.9 Stable May 7, 2025
8.x-1.x-dev Dev May 7, 2025