Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
WCMS
uw_sites_all
Commits
7f448d5a
Commit
7f448d5a
authored
Jan 04, 2021
by
Eric Bremner
Browse files
ISTWCMS-4487: adding extra class for uw-pages
parent
6771eeaf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
0 deletions
+15
-0
uw_sites_all.module
uw_sites_all.module
+15
-0
No files found.
uw_sites_all.module
View file @
7f448d5a
...
...
@@ -109,6 +109,21 @@ function uw_sites_all_page_attachments(array &$page) {
}
}
/**
* Implements template_preprocess_html().
*/
function
uw_sites_all_preprocess_html
(
&
$variables
)
{
// Get the arguments of the URL and separate into parts.
$args
=
explode
(
'/'
,
\
Drupal
::
service
(
'path.current'
)
->
getPath
());
// If the last argument is layout, we are on a layout page,
// so set the variable to true.
if
(
!
in_array
(
'dashboard'
,
$args
))
{
$variables
[
'attributes'
][
'class'
][]
=
'uw-page'
;
}
}
/**
* Implements template_preprocess_block().
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment