...

View Full Version : Resolved help changing background cell color in all browsers



jasondavis
07-22-2009, 07:15 AM
<script>
function mF() {
var l =document.getElementById("boxes");
var t =l.getElementsByTagName("li");
var myTopID =[];
f =Math.min(t.length, N);
for (i =0; i <f; i++) {
myTopID[i] =t[i].title;
//cell background color when selected as a top 4,8,12,16 item
t[i].style.backgroundColor = "cc3333";
//cool(myTopID);
}
document.PageForm.myTopFriends.value = myTopID.join(",");
for (i =N; i <t.length; i++){
//cell background color when NOT selected
t[i].style.backgroundColor = "ebebeb";
}
}
</script>


This line
t[i].style.backgroundColor = "cc3333";
changes the selected cells to a different color, it works perfect in firefox but in google chrome and IE it does not change the color, any help would be awsome in getting this to work

Philip M
07-22-2009, 08:14 AM
t[i].style.backgroundColor = "#cc3333";



All advice is supplied packaged by intellectual weight, and not by volume. Contents may settle slightly in transit.

jasondavis
07-22-2009, 05:14 PM
wow thank you that saves so much headache glad it was something simple



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum