• 0
Sign in to follow this  
Followers 0

Change Background with CSS


Question

Posted · Report post

Hi, sorry about the noob question, but how do I change the background to a CSS gradient/colour in DMS Pagelines?

I have tried pasting the CSS into my child theme's 'style.css' file but it doesn't seem to apply, (I have used this CSS file for other purposes like changing the search bar appearance so I know the document is configured correctly.)

 

I am using the following code:

 

 

/* Background Colour */
#site .custom-background {
background-color: #b0c4de;
}
 
Thanks

Share this post


Link to post
Share on other sites

9 answers to this question

  • 0

Posted · Report post

I apologise use this instead:

 

body .site-wrap { background-color: pink; }

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Thanks Danny, so I have set the background using:

 

 

/* Background Colour*/
.background {
background-color: #bd362f;
}
 
How would I apply this to the whole site?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

You can't use the method on the docs to apply a background color to your whole site. It is there to demonstrate how you can apply different styles to your sections and anything that has the Styling Classes option.

 

If you want to apply a bcakground color to your site, you can use the Content Base Color in DMS Toolbar > Global Options  > Color & Styles.

 

However, this color is then used as a base to calculate different tones throughout your site. If you want to just add a background color, you can apply it using the body class and add that custom CSS to your Custom code.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

When I set the background colour using the following code:

 

 

body {
background-color: yellow;
}
 
It does't display the colour, I must be missing something very obvious.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Thanks, works perfectly!

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

No problem, happy to help!

 

I'll also be adding this to our CSS/LESS Cheatsheet documentation, which is currently in draft.

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Good to know.

Can't wait to get my hands on it!

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

:D

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0