Jump to content
Stef's Coding Community
Sign in to follow this  
jonbey

Could be CSS - background color change not in IE

Recommended Posts

I'm not sure why IE isn't processing the body background. You have a style tag with

<style type="text/css">
body { background-color: #702C53; }
</style>

and it works in Firefox but not in IE, even though it's after the IE conditional comment. I found that if I moved it to the last item before the </head> tag it worked in IE9, perhaps something in the scripts was affecting IE.

<style type="text/css">
/*body { background-color: #702C53; } ......moved down below*/
</style>

<style type="text/css">.recentcomments a{display:inline !
important;padding:0 !important;margin:0 !important;}
</style>

<style type="text/css">.broken_link, a.broken_link {
text-decoration: line-through;
}
</style>
<script type="text/javascript">var analyticsFileTypes = [''];
var analyticsEventTracking = 'enabled';</script> 

<script type="text/javascript">var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-470187-29']);
_gaq.push(['_trackPageview']);
_gaq.push(['_trackPageLoadTime']);
(function() {
	var ga = document.createElement('script'); 
ga.type = 'text/javascript'; ga.async = true;
	ga.src = ('https:' == 
document.location.protocol ? 'https://ssl' : 'http://www') + 
'.google-analytics.com/ga.js';
	var s = document.getElementsByTagName
('script')[0]; s.parentNode.insertBefore(ga, s);
})();</script> 
<style type="text/css">
body { background-color: #702C53; } /* ..........moved here */
</style>
</head>

I found that even if I added background-color: #702C53; to the ie stylesheet it still didn't work in IE.

You have a real jumble of style tags in the head section, but the style tag with the background should have worked as it was one of the last ones.

Edited by Wickham

Share this post


Link to post
Share on other sites

Instead of using background-color, try just background: #702C53;

 

...and Wickham is right, it's a jumble of codes you have.

Share this post


Link to post
Share on other sites

If you want then make external css for your website and use all functions in it.

 

Did you even read what's in this thread or look at the link (and the source code)?

Share this post


Link to post
Share on other sites

Did you even read what's in this thread or look at the link (and the source code)?

I'm just surprised that you just don't delete the account along with a couple of others because they have nothing useful to say in regards to other valid users questions.

Share this post


Link to post
Share on other sites

I'm just surprised that you just don't delete the account along with a couple of others because they have nothing useful to say in regards to other valid users questions.

 

You have a point, I just thought I'd give them another chance and hope they figure out the purpose of the forum - or go away on their own.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...