March 30, 2012

My <body> isn't accepting background color/image

Question by langel

CSS code

body { 
    background-attachment: scroll;
    background-clip: border-box;
    background-color: #ececec;
    background-image: none;
    background-origin: padding-box;

}

Link: http://grupocoral.netai.net/

No matter what I do I can’t change background properties.

Answer by Engineer

Remove <style type="text/css"> and </style> from your css file.

Answer by Starx

You have placed your CSS code in the style sheet along with the <style> tags. You shouldn’t do that when attaching an external CSS stylesheet. You can directly define the styles.

Remove

<style type="text/css"> & </style> from your file style.css

Author: Nabin Nepal (Starx)

Hello, I am Nabin Nepal and you can call me Starx. This is my blog where write about my life and my involvements. I am a Software Developer, A Cyclist and a Realist. I hope you will find my blog interesting. Follow me on Google+

...

Please fill the form - I will response as fast as I can!